ViewVC Help
View File | Revision Log | Show Annotations | Revision Graph | Root Listing
root/i-scream/projects/cms/source/ihost/libstatgrab/os_info.c
(Generate patch)

Comparing projects/cms/source/ihost/libstatgrab/os_info.c (file contents):
Revision 1.1 by pajs, Mon May 13 14:42:11 2002 UTC vs.
Revision 1.3 by tdb, Mon May 13 16:46:24 2002 UTC

# Line 9 | Line 9
9   #include <sys/types.h>
10   #include <sys/sysctl.h>
11   #include <time.h>
12 + #include <sys/time.h>
13   #endif
14  
15   char *get_os_info(){
# Line 27 | Line 28 | char *get_os_info(){
28   #ifdef FREEBSD
29          struct timeval boottime;
30          time_t curtime;
31 +        size_t size;
32   #endif
33          if((uname(&os)) < 0){
34                  errf("Failed to get os stats (%m)");
# Line 90 | Line 92 | char *get_os_info(){
92   #endif
93  
94  
95 <        xml_os_info=strf("<os><name>%s</name><release>%s</release><version>%s</version><sysname>%s</sysname><platform>%s</platform><uptime>%ld</uptime>", os.sysname, os.release, os.version, os.nodename, os.machine, uptime);
95 >        xml_os_info=strf("<os><name>%s</name><release>%s</release><version>%s</version><sysname>%s</sysname><platform>%s</platform><uptime>%ld</uptime></os>", os.sysname, os.release, os.version, os.nodename, os.machine, uptime);
96  
95        printf("%s\n",xml_os_info);
97          return xml_os_info;
97 }
98
99 int main(){
100        get_os_info();
101        exit(0);
98   }

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines