aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorChong Yidong2008-07-25 18:05:01 +0000
committerChong Yidong2008-07-25 18:05:01 +0000
commitf100213ed14527a61c10bb9a31441c8396fceba2 (patch)
tree90e9c43bc2ea6db2a95dba990618efdc3c5920cf /src
parent5efc62005ae094bae44ff800b1ad5af9485ff202 (diff)
downloademacs-f100213ed14527a61c10bb9a31441c8396fceba2.tar.gz
emacs-f100213ed14527a61c10bb9a31441c8396fceba2.zip
(nl): Rename to name_list to avoid ncurses.h clash (bug#86).
(getloadavg): Callers changed.
Diffstat (limited to 'src')
-rw-r--r--src/getloadavg.c28
1 files changed, 14 insertions, 14 deletions
diff --git a/src/getloadavg.c b/src/getloadavg.c
index 32d0f41a4a9..a174fc07a01 100644
--- a/src/getloadavg.c
+++ b/src/getloadavg.c
@@ -490,7 +490,7 @@ static int getloadavg_initialized;
490static long offset; 490static long offset;
491 491
492# if !defined(VMS) && !defined(sgi) && !defined(__linux__) 492# if !defined(VMS) && !defined(sgi) && !defined(__linux__)
493static struct nlist nl[2]; 493static struct nlist name_list[2];
494# endif /* Not VMS or sgi */ 494# endif /* Not VMS or sgi */
495 495
496# ifdef SUNOS_5 496# ifdef SUNOS_5
@@ -880,32 +880,32 @@ getloadavg (loadavg, nelem)
880 { 880 {
881# ifndef sgi 881# ifndef sgi
882# ifndef NLIST_STRUCT 882# ifndef NLIST_STRUCT
883 strcpy (nl[0].n_name, LDAV_SYMBOL); 883 strcpy (name_list[0].n_name, LDAV_SYMBOL);
884 strcpy (nl[1].n_name, ""); 884 strcpy (name_list[1].n_name, "");
885# else /* NLIST_STRUCT */ 885# else /* NLIST_STRUCT */
886# ifdef HAVE_STRUCT_NLIST_N_UN_N_NAME 886# ifdef HAVE_STRUCT_NLIST_N_UN_N_NAME
887 nl[0].n_un.n_name = LDAV_SYMBOL; 887 name_list[0].n_un.n_name = LDAV_SYMBOL;
888 nl[1].n_un.n_name = 0; 888 name_list[1].n_un.n_name = 0;
889# else /* not HAVE_STRUCT_NLIST_N_UN_N_NAME */ 889# else /* not HAVE_STRUCT_NLIST_N_UN_N_NAME */
890 nl[0].n_name = LDAV_SYMBOL; 890 name_list[0].n_name = LDAV_SYMBOL;
891 nl[1].n_name = 0; 891 name_list[1].n_name = 0;
892# endif /* not HAVE_STRUCT_NLIST_N_UN_N_NAME */ 892# endif /* not HAVE_STRUCT_NLIST_N_UN_N_NAME */
893# endif /* NLIST_STRUCT */ 893# endif /* NLIST_STRUCT */
894 894
895# ifndef SUNOS_5 895# ifndef SUNOS_5
896 if ( 896 if (
897# if !(defined (_AIX) && !defined (ps2)) 897# if !(defined (_AIX) && !defined (ps2))
898 nlist (KERNEL_FILE, nl) 898 nlist (KERNEL_FILE, name_list)
899# else /* _AIX */ 899# else /* _AIX */
900 knlist (nl, 1, sizeof (nl[0])) 900 knlist (name_list, 1, sizeof (name_list[0]))
901# endif 901# endif
902 >= 0) 902 >= 0)
903 /* Omit "&& nl[0].n_type != 0 " -- it breaks on Sun386i. */ 903 /* Omit "&& name_list[0].n_type != 0 " -- it breaks on Sun386i. */
904 { 904 {
905# ifdef FIXUP_KERNEL_SYMBOL_ADDR 905# ifdef FIXUP_KERNEL_SYMBOL_ADDR
906 FIXUP_KERNEL_SYMBOL_ADDR (nl); 906 FIXUP_KERNEL_SYMBOL_ADDR (name_list);
907# endif 907# endif
908 offset = nl[0].n_value; 908 offset = name_list[0].n_value;
909 } 909 }
910# endif /* !SUNOS_5 */ 910# endif /* !SUNOS_5 */
911# else /* sgi */ 911# else /* sgi */
@@ -941,8 +941,8 @@ getloadavg (loadavg, nelem)
941 if (kd != 0) 941 if (kd != 0)
942 { 942 {
943 /* nlist the currently running kernel. */ 943 /* nlist the currently running kernel. */
944 kvm_nlist (kd, nl); 944 kvm_nlist (kd, name_list);
945 offset = nl[0].n_value; 945 offset = name_list[0].n_value;
946 getloadavg_initialized = 1; 946 getloadavg_initialized = 1;
947 } 947 }
948# endif /* SUNOS_5 */ 948# endif /* SUNOS_5 */