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

Comparing projects/libstatgrab/src/libstatgrab/page_stats.c (file contents):
Revision 1.10 by ats, Fri Oct 24 17:26:43 2003 UTC vs.
Revision 1.11 by ats, Mon Nov 10 23:25:45 2003 UTC

# Line 30 | Line 30
30   #include <sys/sysinfo.h>
31   #include <string.h>
32   #endif
33 < #ifdef LINUX
33 > #if defined(LINUX) || defined(CYGWIN)
34   #include <stdio.h>
35   #include <string.h>
36   #endif
# Line 48 | Line 48 | page_stat_t *get_page_stats(){
48          kstat_t *ksp;
49          cpu_stat_t cs;
50   #endif
51 < #ifdef LINUX
51 > #if defined(LINUX) || defined(CYGWIN)
52          FILE *f;
53          char *line_ptr;
54   #endif
# Line 79 | Line 79 | page_stat_t *get_page_stats(){
79  
80          kstat_close(kc);
81   #endif
82 < #ifdef LINUX
82 > #if defined(LINUX) || defined(CYGWIN)
83          if ((f = fopen("/proc/vmstat", "r")) != NULL) {
84                  while ((line_ptr = f_read_line(f, "")) != NULL) {
85                          long long value;

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines