diff options
author | Benoît Dejean <bdejean@src.gnome.org> | 2005-08-02 09:47:21 +0000 |
---|---|---|
committer | Benoît Dejean <bdejean@src.gnome.org> | 2005-08-02 09:47:21 +0000 |
commit | 78cb7832c50f0cbb8225a201d46539198cf99a25 (patch) | |
tree | 907169723e04fa7a360739f8ca00c714e7104efd /include/glibtop | |
parent | b3979e69426cd74386ed9fc6e99f55a4ec353b88 (diff) | |
download | libgtop-78cb7832c50f0cbb8225a201d46539198cf99a25.tar.gz |
Moved _glibtop_init_hook_[sp] declaration to private glibtop/init_hooks.h.
* configure.in:
* include/glibtop/Makefile.am:
* include/glibtop/glibtop-server.h:
* include/glibtop/init_hooks.h:
* include/glibtop/sysdeps.h:
* lib/init.c: (glibtop_init_s):
* lib/sysdeps.c:
* sysdeps/aix/open.c: (glibtop_init_p):
* sysdeps/common/sysdeps_suid.c:
* sysdeps/freebsd/open.c: (glibtop_init_p):
* sysdeps/osf1/open_suid.c: (glibtop_init_p):
* sysdeps/solaris/open_suid.c: (glibtop_init_p):
* sysdeps/stub_suid/open.c: (glibtop_init_p):
Moved _glibtop_init_hook_[sp] declaration to private
glibtop/init_hooks.h. Marked them const.
Fixed GLIBTOP_SUID_NETLIST issues.
Diffstat (limited to 'include/glibtop')
-rw-r--r-- | include/glibtop/Makefile.am | 2 | ||||
-rw-r--r-- | include/glibtop/glibtop-server.h | 5 | ||||
-rw-r--r-- | include/glibtop/init_hooks.h | 11 | ||||
-rw-r--r-- | include/glibtop/sysdeps.h | 4 |
4 files changed, 12 insertions, 10 deletions
diff --git a/include/glibtop/Makefile.am b/include/glibtop/Makefile.am index 2940a2e9..4b1bdb1e 100644 --- a/include/glibtop/Makefile.am +++ b/include/glibtop/Makefile.am @@ -10,4 +10,4 @@ glibtop_HEADERS = close.h loadavg.h prockernel.h procstate.h \ inodedb.h sysinfo.h ppp.h procargs.h netload.h \ netlist.h procopenfiles.h open.h -noinst_HEADERS = error.h write.h read_data.h read.h +noinst_HEADERS = error.h write.h read_data.h read.h init_hooks.h diff --git a/include/glibtop/glibtop-server.h b/include/glibtop/glibtop-server.h index 53730fa3..13878b39 100644 --- a/include/glibtop/glibtop-server.h +++ b/include/glibtop/glibtop-server.h @@ -36,11 +36,6 @@ typedef struct _glibtop_server_info glibtop_server_info; typedef struct _glibtop_closure glibtop_closure; -typedef int (*glibtop_init_func_t) (glibtop_server *, glibtop_closure *); - -extern glibtop_init_func_t _glibtop_init_hook_s []; -extern glibtop_init_func_t _glibtop_init_hook_p []; - struct _glibtop_server_info { int ncpu; /* Number of CPUs, zero if single-processor */ diff --git a/include/glibtop/init_hooks.h b/include/glibtop/init_hooks.h new file mode 100644 index 00000000..e26be6ec --- /dev/null +++ b/include/glibtop/init_hooks.h @@ -0,0 +1,11 @@ +#ifndef H_LIBGTOP_INIT_HOOKS_1122955666 +#define H_LIBGTOP_INIT_HOOKS_1122955666 + +#include <glibtop.h> + +typedef void (*glibtop_init_func_t)(glibtop *); + +extern const glibtop_init_func_t _glibtop_init_hook_s[]; +extern const glibtop_init_func_t _glibtop_init_hook_p[]; + +#endif /* H_LIBGTOP_INIT_HOOKS_1122955666 */ diff --git a/include/glibtop/sysdeps.h b/include/glibtop/sysdeps.h index 545e796c..23d65c7f 100644 --- a/include/glibtop/sysdeps.h +++ b/include/glibtop/sysdeps.h @@ -58,10 +58,6 @@ G_BEGIN_DECLS #define GLIBTOP_SYSDEPS_ALL ((1 << GLIBTOP_MAX_SYSDEPS) - 1) -typedef void (*glibtop_init_func_t) (glibtop *); -extern glibtop_init_func_t _glibtop_init_hook_s []; -extern glibtop_init_func_t _glibtop_init_hook_p []; - typedef struct _glibtop_sysdeps glibtop_sysdeps; struct _glibtop_sysdeps |