projects
/
chise
/
xemacs-chise.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Sync up with r21-2-16.
[chise/xemacs-chise.git]
/
src
/
getloadavg.c
diff --git
a/src/getloadavg.c
b/src/getloadavg.c
index
9af7e53
..
b8161e4
100644
(file)
--- a/
src/getloadavg.c
+++ b/
src/getloadavg.c
@@
-19,8
+19,6
@@
along with XEmacs; see the file COPYING. If not, write to
the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-#ifndef __CYGWIN32__
-
/* Compile-time symbols that this file uses:
FIXUP_KERNEL_SYMBOL_ADDR() Adjust address in returned struct nlist.
/* Compile-time symbols that this file uses:
FIXUP_KERNEL_SYMBOL_ADDR() Adjust address in returned struct nlist.
@@
-58,7
+56,7
@@
Boston, MA 02111-1307, USA. */
__linux__ Linux: assumes /proc filesystem mounted.
Support from Michael K. Johnson.
__NetBSD__ NetBSD: assumes /kern filesystem mounted.
__linux__ Linux: assumes /proc filesystem mounted.
Support from Michael K. Johnson.
__NetBSD__ NetBSD: assumes /kern filesystem mounted.
- __OpenBSD__ OpenBSD: dito.
+ __OpenBSD__ OpenBSD: ditto.
In addition, to avoid nesting many #ifdefs, we internally set
LDAV_DONE to indicate that the load average has been computed.
In addition, to avoid nesting many #ifdefs, we internally set
LDAV_DONE to indicate that the load average has been computed.
@@
-71,6
+69,9
@@
Boston, MA 02111-1307, USA. */
#include <config.h>
#endif
#include <config.h>
#endif
+#ifndef WINDOWSNT
+#ifndef __CYGWIN32__
+
#include <sys/types.h>
/* Both the Emacs and non-Emacs sections want this. Some
#include <sys/types.h>
/* Both the Emacs and non-Emacs sections want this. Some
@@
-563,7
+564,8
@@
getloadavg (double loadavg[], int nelem)
}
for (elem = 0; elem < nelem; elem++)
{
}
for (elem = 0; elem < nelem; elem++)
{
- kstat_named_t *kn = kstat_data_lookup (ksp, avestrings[elem]);
+ kstat_named_t *kn =
+ (kstat_named_t *) kstat_data_lookup (ksp, avestrings[elem]);
if (!kn)
{
kstat_close (kc);
if (!kn)
{
kstat_close (kc);
@@
-1005,4
+1007,4
@@
getloadavg (double loadavg[], int nelem)
}
#endif /*__GNUWIN32__*/
}
#endif /*__GNUWIN32__*/
-
+#endif /* WINDOWSNT */