about summary refs log tree commit diff
path: root/sysdeps/unix/sysv/linux
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2001-02-11 19:15:00 +0000
committerUlrich Drepper <drepper@redhat.com>2001-02-11 19:15:00 +0000
commite4cf522929cc33ea951756509b0e4f166f0da59a (patch)
treee072b02cf33d98bde5e8e82a9ddfa4316b299020 /sysdeps/unix/sysv/linux
parent5b8d5ae180f8e9d899a28c96bae77f1e8ef29cf8 (diff)
downloadglibc-e4cf522929cc33ea951756509b0e4f166f0da59a.tar.gz
glibc-e4cf522929cc33ea951756509b0e4f166f0da59a.tar.xz
glibc-e4cf522929cc33ea951756509b0e4f166f0da59a.zip
Update.
	* sysdeps/generic/getsysstat.c: Change return value of get_phys_pages
	and get_avphys_page to long int.
	* sysdeps/unix/sysv/linux/getsysstat.c: Likewise.
	* include/sys/sysinfo.h: Likewise.
	* sysdeps/generic/sys/sysinfo.h: Likewise.
	* sysdeps/unix/sysv/linux/sys/sysinfo.h: Likewise.
Diffstat (limited to 'sysdeps/unix/sysv/linux')
-rw-r--r--sysdeps/unix/sysv/linux/getsysstats.c14
-rw-r--r--sysdeps/unix/sysv/linux/sys/sysinfo.h8
2 files changed, 11 insertions, 11 deletions
diff --git a/sysdeps/unix/sysv/linux/getsysstats.c b/sysdeps/unix/sysv/linux/getsysstats.c
index 9a2d7cfcda..d8808ff69a 100644
--- a/sysdeps/unix/sysv/linux/getsysstats.c
+++ b/sysdeps/unix/sysv/linux/getsysstats.c
@@ -1,5 +1,5 @@
 /* Determine various system internal values, Linux version.
-   Copyright (C) 1996, 1997, 1998, 1999, 2000 Free Software Foundation, Inc.
+   Copyright (C) 1996,1997,1998,1999,2000,2001 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by Ulrich Drepper <drepper@cygnus.com>, 1996.
 
@@ -203,14 +203,14 @@ weak_alias (__get_nprocs_conf, get_nprocs_conf)
 
 /* General function to get information about memory status from proc
    filesystem.  */
-static int
+static long int
 internal_function
 phys_pages_info (const char *format)
 {
   FILE *fp;
   char buffer[8192];
   const char *proc_path;
-  int result = -1;
+  long int result = -1;
 
   /* Get mount point of proc filesystem.  */
   proc_path = get_proc_path (buffer, sizeof buffer);
@@ -258,12 +258,12 @@ phys_pages_info (const char *format)
 
    But not all systems have support for the /proc filesystem.  If it
    is not available we return -1 as an error signal.  */
-int
+long int
 __get_phys_pages ()
 {
   /* XXX Here will come a test for the new system call.  */
 
-  return phys_pages_info ("MemTotal: %d kB");
+  return phys_pages_info ("MemTotal: %ld kB");
 }
 weak_alias (__get_phys_pages, get_phys_pages)
 
@@ -279,12 +279,12 @@ weak_alias (__get_phys_pages, get_phys_pages)
 
    But not all systems have support for the /proc filesystem.  If it
    is not available we return -1 as an error signal.  */
-int
+long int
 __get_avphys_pages ()
 {
   /* XXX Here will come a test for the new system call.  */
 
-  return phys_pages_info ("MemFree: %d kB");
+  return phys_pages_info ("MemFree: %ld kB");
 }
 weak_alias (__get_avphys_pages, get_avphys_pages)
 
diff --git a/sysdeps/unix/sysv/linux/sys/sysinfo.h b/sysdeps/unix/sysv/linux/sys/sysinfo.h
index 2f2b4dfbce..c786f7c348 100644
--- a/sysdeps/unix/sysv/linux/sys/sysinfo.h
+++ b/sysdeps/unix/sysv/linux/sys/sysinfo.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 1996, 1999 Free Software Foundation, Inc.
+/* Copyright (C) 1996, 1999, 2001 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
    The GNU C Library is free software; you can redistribute it and/or
@@ -17,8 +17,8 @@
    Boston, MA 02111-1307, USA.  */
 
 #ifndef _SYS_SYSINFO_H
-
 #define _SYS_SYSINFO_H	1
+
 #include <features.h>
 
 /* Get sysinfo structure from kernel header.  */
@@ -38,10 +38,10 @@ extern int get_nprocs (void) __THROW;
 
 
 /* Return number of physical pages of memory in the system.  */
-extern int get_phys_pages (void) __THROW;
+extern long int get_phys_pages (void) __THROW;
 
 /* Return number of available physical pages of memory in the system.  */
-extern int get_avphys_pages (void) __THROW;
+extern long int get_avphys_pages (void) __THROW;
 
 __END_DECLS