summaryrefslogtreecommitdiff
path: root/sysdeps/linux/glibtop_server.h
Commit message (Collapse)AuthorAgeFilesLines
* Copy stub sysdeps files to other OS impls to reduce compile errors.ToMe252021-04-241-1/+1
|
* Revert "Revert "New API to retrieve disk stats in Linux""James Dominic P. Guana2021-04-231-0/+1
| | | | This reverts commit 7e214414bf23d1ea34e7fdccb17a7f41040ffea9.
* Revert "New API to retrieve disk stats in Linux"Michael Catanzaro2020-11-061-1/+0
| | | | This reverts commit 9e62440b314fbf87bbeca865a4223311314c52a3.
* New API to retrieve disk stats in LinuxJames Dominic P. Guana2020-11-041-0/+1
|
* glibtop_get_proc_map on Linux doesn't need to be SUID.Benoît Dejean2018-03-261-1/+1
| | | | | Revert this proof of concept. Add C file with comments to document how to make a call SUID.
* Make linux build with server.Benoît Dejean2018-03-261-1/+1
| | | | | Add suid infrastructure. Demo proc_map.
* Rename GLIBTOP_SUID_PROC_FILE to GLIBTOP_SUID_PROC_OPEN_FILES.Benoît Dejean2018-03-071-1/+1
| | | | | | | | | The previous name is incorrect and inconsistent with the code generated by lib.pl. Also add missing hooks. This symbol, although exposed in public headers is not part of the API and is only used internally.
* Renamed procdiskio to procioRobert Roth2017-05-121-1/+1
|
* New API to retrieve process io stats, with Linux implementationRobert Roth2017-02-121-0/+1
|
* Update old FSF address.Robert Roth2014-08-201-2/+2
| | | | https://bugzilla.gnome.org/show_bug.cgi?id=721514
* New API to retrieve process CPU affinity.Benoît Dejean2008-05-241-0/+1
| | | | | | Linux implementation. svn path=/trunk/; revision=2748
* git-svn sucks. Kill r2609Benoît Dejean2007-06-251-1/+0
| | | | svn path=/trunk/; revision=2611
* New API : glibtop_get_proc_affinity.Benoît Dejean2007-06-251-0/+1
| | | | | | Implemented for linux. svn path=/trunk/; revision=2609
* Manual commit from my local git-svn which is broken :/Benoît Dejean2007-05-131-0/+1
| | | | svn path=/trunk/; revision=2578
* Removed noisy $Id$.Benoît Dejean2007-02-191-2/+0
| | | | | | | | | | 2007-02-20 Benoît Dejean <benoit@placenet.org> * *: Removed noisy $Id$. svn path=/trunk/; revision=2558
* Added GLIBTOP_SUID_NETLIST.Benoît Dejean2005-08-021-0/+1
| | | | | | * glibtop_server.h: Added GLIBTOP_SUID_NETLIST.
* Disabled.Benoît Dejean2005-01-101-0/+1
| | | | | | | * glibtop_server.h: * procopenfiles.c: (get_socket_endpoint): Disabled. (glibtop_get_proc_open_files_s): Secured -> g_snprintf.
* Added Added RemovedBenoît Dejean2004-11-281-104/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | * Makefile.am: * cpu.c: * fsusage.c: * glibtop_private.c: (get_scaled), (try_file_to_buffer), (file_to_buffer): Added * glibtop_private.h: Added * glibtop_server.c: Removed * glibtop_server.h: * loadavg.c: * mem.c: * netload.c: * open.c: * prockernel.c: * procmem.c: * procsegment.c: * procsignal.c: * procstate.c: * proctime.c: * procuid.c: * swap.c: * sysinfo.c: * uptime.c: Moved linux impl utils function from glibtop_server.* to glibtob_private.* because glibtop_server.h is a public header.
* Removed get_pageshift(). Every one can affort a * instead of a >>, no needBenoît Dejean2004-09-231-2/+0
| | | | | | | | | * glibtop_server.c: * glibtop_server.h: * procmem.c: (glibtop_get_proc_mem_s): * procsegment.c: (glibtop_get_proc_segment_s): Removed get_pageshift(). Every one can affort a * instead of a >>, no need for this kind of non-reentrant optimization. Saved 144B (obviously perfect cleanup ;)
* bumped to 2.8.1.Benoît Dejean2004-09-131-1/+1
| | | | | | | | | | | | | * configure.in: bumped to 2.8.1. * sysdeps/common/fsusage.c: * sysdeps/common/gnuslib.c: (glibtop_make_connection), (connect_to_unix_server), (glibtop_internet_addr): * sysdeps/linux/glibtop_server.c: (get_pageshift): * sysdeps/linux/glibtop_server.h: * sysdeps/linux/open.c: (glibtop_open_s): * sysdeps/linux/ppp.c: (is_ISDN_on): Cleanups. Thanks to Kjartan Maraas. Closes #151557.
* Added next_token(). Changed skip_token(), i hope it won't break any badBenoît Dejean2004-08-031-1/+8
| | | | | | | | * glibtop_server.h: Added next_token(). Changed skip_token(), i hope it won't break any bad code. * procstate.c: (glibtop_get_proc_state_s): Used next_token. * proctime.c: (glibtop_get_proc_time_s): Implemented .start_time the way it ought to be. Clean ups.
* Added to repository. WIP.Benoît Dejean2004-07-171-1/+1
| | | | | | | | | | | | | | | | | | | * Makefile.am: * fsusage.c: (linux_2_6_0), (linux_2_4_0), (_glibtop_linux_get_fsusage_read_write): Added to repository. WIP. * glibtop_server.h: LINUX_VERSION -> LINUX_VERSION_CODE * netload.c: (glibtop_get_netload_s): Cleanups. Added support for hardware address. s/LINUX_VERSION/LINUX_VERSION_CODE/ * open.c: (get_linux_version): s/LINUX_VERSION/LINUX_VERSION_CODE/ * procmap.c: (glibtop_get_proc_map_s): glibify: used GArray * procuid.c: (glibtop_get_proc_uid_s): s/LINUX_VERSION/LINUX_VERSION_CODE/. Used Linux MKDEV.
* Added. These functions are commonly used. Misc cleanups.Benoît Dejean2004-07-031-4/+27
| | | | | | | | | | | | | | * glibtop_server.h: * glibtop_server.c: (try_file_to_buffer), (file_to_buffer): Added. These functions are commonly used. Misc cleanups. * cpu.c: (glibtop_get_cpu_s): * loadavg.c: (glibtop_get_loadavg_s): * mem.c: (glibtop_get_mem_s): * open.c: (glibtop_open_s): * swap.c: (glibtop_get_swap_s): * sysinfo.c: (init_sysinfo): * uptime.c: (glibtop_get_uptime_s): Replaced open/read/close by file_to_buffer().
* Whitespace cleanup.Benoît Dejean2004-06-181-3/+6
| | | | | | | | | | | | | | | | | | * loadavg.c: (glibtop_get_loadavg_s): Whitespace cleanup. * ppp.c: (get_ISDN_stats), (is_ISDN_on): Replace g_malloc by an array. * glibtop_server.c: (get_pageshift): * glibtop_server.h: * procmem.c: (glibtop_init_proc_mem_s), (glibtop_get_proc_mem_s): * procsegment.c: (glibtop_init_proc_segment_s), (glibtop_get_proc_segment_s): Moved the pageshift calculation to glibtop_server.[ch] * procstate.c: (glibtop_get_proc_state_s): * procuid.c: (glibtop_get_proc_uid_s): * sysinfo.c: (init_sysinfo): Minor cleanups.
* Cleaned. (proc_file_to_buffer): Uninlined.Benoît Dejean2004-06-121-21/+2
| | | | | | | | * glibtop_server.h: * glibtop_server.c: (get_scaled): Cleaned. (proc_file_to_buffer): Uninlined. * sysinfo.c: (init_sysinfo): Re-implemented.
* Added to repository.Benoît Dejean2004-06-121-21/+6
| | | | | | | | | | | | | | | | | | | | | | * Makefile.am: * glibtop_server.c: Added to repository. * glibtop_server.h: (get_scaled): Uninlined and moved it to glibtop_server.c. (skip_token) : Fixed indentation. * procmap.c: (glibtop_get_proc_map_s): Big cleanup. Better allocation algorithm. * procmem.c: * procsegment.c: Added missing initializations. * sem_limits.c: * shm_limits.c: (glibtop_get_shm_limits_s): * swap.c: * uptime.c: Added missing const qualifiers. * sysinfo.c: (init_sysinfo): Added missing 0 initialization. Saved 1 gboolean :D.
* Small clean up.Benoît Dejean2004-06-081-4/+2
| | | | * glibtop_server.h: Small clean up.
* Removed. Cleaned. Replaced unsafe strcpy by g_strlcpy.Benoît Dejean2004-06-061-2/+2
| | | | | | | | | * glibtop_machine.h (skip_token): Removed. * glibtop_server.h (skip_multiple_token): Cleaned. * netload.c: (glibtop_get_netload_s): Replaced unsafe strcpy by g_strlcpy. * procmap.c: (glibtop_get_proc_map_s): s/strncpy/g_strlcpy/. * procstate.c: (glibtop_get_proc_state_s): Likewise. * sysinfo.c: (init_sysinfo): Cleaned.
* Moved LINUX_VERSION macro to glibtop_server.h.Benoît Dejean2004-05-261-0/+2
| | | | | | | | * glibtop_server.h: * open.c: * procuid.c: Moved LINUX_VERSION macro to glibtop_server.h. * Changelog: Converted to UTF-8.
* Added test for end of string. (get_scaled): Cleaned.Benoît Dejean2004-05-251-3/+4
| | | | | | | | | * glibtop_server.h (skip_line): Added test for end of string. (get_scaled): Cleaned. * cpu.c (glibtop_get_cpu_s): * open.c (glibtop_open_s): Fixed SMP detection. Closes #142597. * uptime.c (glibtop_get_uptime_s): Added boot_time.
* Apply patch from Benoît Dejean <bnet@ifrance.com> to fix overflow issuesBastien Nocera2003-12-231-3/+3
| | | | | | | | | | | | | | | | | | | 2003-12-23 Bastien Nocera <hadess@hadess.net> * cpu.c: (glibtop_get_cpu_s): * glibtop_server.h: * loadavg.c: (glibtop_get_loadavg_s): * mem.c: (glibtop_get_mem_s): * netload.c: (glibtop_get_netload_s): * prockernel.c: (glibtop_get_proc_kernel_s): * procmem.c: (glibtop_get_proc_mem_s): * procsegment.c: (glibtop_get_proc_segment_s): * procsignal.c: (glibtop_get_proc_signal_s): * proctime.c: (glibtop_get_proc_time_s): * procuid.c: (glibtop_get_proc_uid_s): * swap.c: (glibtop_get_swap_s): Apply patch from Benoît Dejean <bnet@ifrance.com> to fix overflow issues using strtol (Closes: #129881)
* committing patch from Sebastien Bacher <seb128@debian.org> for Linux 2.6Bastien Nocera2003-10-201-0/+19
| | | | | | | | | 2003-10-20 Bastien Nocera <hadess@hadess.net> * glibtop_server.h: * mem.c: (glibtop_get_mem_s): * swap.c: (glibtop_get_swap_s): committing patch from Sebastien Bacher <seb128@debian.org> for Linux 2.6 support (Closes: #104747)
* - fixed compilationBastien Nocera2003-10-201-2/+2
|
* Reverted libgtop changes. It's a common module and I should not modify it.Carlos Perelló Marín2003-10-191-0/+135
| | | | | | | | 2003-10-19 Carlos Perelló Marín <carlos@gnome.org> * support/*: Reverted libgtop changes. It's a common module and I should not modify it. * Added/removed files. Now the move should be done.
* Moved all sysdeps code to the new libgtop-backends module.Martin Baulig2001-04-201-139/+0
| | | | | | | | | | | | | | | 2001-04-20 Martin Baulig <baulig@suse.de> Moved all sysdeps code to the new libgtop-backends module. * sysdeps/freesd/*: Removed. * sysdeps/kernel/*: Removed. * sysdeps/linux/*: Removed. * sysdeps/osf1/*: Removed. * sysdeps/solaris/*: Removed. * sysdeps/stub/*: Removed. * sysdeps/stub_suid/*: Removed. * sysdeps/sun4/*: Removed.
* Make sure we close all open files.Martin Baulig2000-02-141-2/+3
|
* The indentation in LibGTop was done with the following command:Martin Baulig1999-12-261-26/+28
| | | | | | | | find . -name \*.[ch] | xargs -i emacs -batch {} \ -l /gnome/compile/libgtop/misc/format.el -f save-buffer December 26, 1999 Martin
* Split netload into netload and netinfo.Martin Baulig1999-11-281-0/+1
| | | | | | | | | | | | | | | | 1999-11-28 Martin Baulig <martin@home-of-linux.org> Split netload into netload and netinfo. * include/glibtop/netinfo.h: New file. * include/glibtop/netload.h (glibtop_netload): Moved `if_flags', `mtu', `subnet' and `address' into the new `glibtop_netinfo'. * include/glibtop/sysdeps.h (GLIBTOP_SYSDEPS_NETINFO): Added. (glibtop_sysdeps): Added `netinfo. * include/glibtop/union.h (glibtop_union): Added `netinfo. * include/glibtop/command.h (GLIBTOP_CMND_NETINFO): Added.
* New file. (glibtop_init_interface_names_s): New function.Martin Baulig1999-11-211-0/+1
| | | | | | | | 1999-11-21 Martin Baulig <martin@home-of-linux.org> * interfaces.c: New file. (glibtop_init_interface_names_s): New function. (glibtop_get_interface_names_s): New function.
* Set the copyright of LibGTop to the GNU General Public License.Martin Baulig1999-02-231-7/+7
| | | | | | | | | 1999-02-22 Martin Baulig <martin@home-of-linux.org> Set the copyright of LibGTop to the GNU General Public License. * copyright.txt: Set the year to 1998-99 and pretty-format it a little bit. Same in all C source and header files.
* Include a copy of the GNU Library General Public License here.Martin Baulig1999-02-221-13/+15
| | | | | | | | | | 1999-02-22 Martin Baulig <martin@home-of-linux.org> * COPYING.LIB: Include a copy of the GNU Library General Public License here. * copyright.txt: Set the year to 1998-99 and pretty-format it a little bit. Same in all C source and header files.
* Replace all __BEGIN_DELCS with LIBGTOP_BEGIN_DECLS and all __END_DECLSMartin Baulig1999-02-191-2/+2
| | | | | | | | 1999-02-19 Martin Baulig <martin@home-of-linux.org> * Replace all __BEGIN_DELCS with LIBGTOP_BEGIN_DECLS and all __END_DECLS with LIBGTOP_END_DECLS; remove all __P macros and use real function prototypes.
* Added new features to get network load:Martin Baulig1998-10-261-0/+3
| | | | | | | | | | | | | | | | | | | | | | | typedef struct _glibtop_netload glibtop_netload; struct _glibtop_netload { u_int64_t flags, mtu, /* GLIBTOP_NETLOAD_MTU */ address, /* GLIBTOP_NETLOAD_ADDRESS */ packets_in, /* GLIBTOP_NETLOAD_PACKETS_IN */ packets_out, /* GLIBTOP_NETLOAD_PACKETS_OUT */ bytes_in, /* GLIBTOP_NETLOAD_BYTES_IN */ bytes_out, /* GLIBTOP_NETLOAD_BYTES_OUT */ errors_in, /* GLIBTOP_NETLOAD_ERRORS_IN */ errors_out, /* GLIBTOP_NETLOAD_ERRORS_OUT */ collisions; /* GLIBTOP_NETLOAD_COLLISIONS */ }; Returns network load of the given interface, it is specified as string like `isppp' or `ippp0': extern void glibtop_get_netload_l __P((glibtop *, glibtop_netload *, const char *));
* Small bug fixes.Martin Baulig1998-08-171-1/+1
|
* Major code cleanups. We now use open () and read ().Martin Baulig1998-08-161-0/+64
|
* Major code cleanups, we now use open () and read ().Martin Baulig1998-08-161-0/+18
|
* Using `text_rss', `shlib_rss', `data_rss' and `dirty_size' instead ofMartin Baulig1998-08-121-0/+1
| | | | | | | | | | | | | | | | | | | 1998-08-12 Martin Baulig <martin@home-of-linux.org> * include/glibtop/procsegment.h (glibtop_proc_segment): Using `text_rss', `shlib_rss', `data_rss' and `dirty_size' instead of `tsr', `lrs', `drs' and `dt'. New field `stack_rss'. * sysdeps/linux/procmem.c: Memory sizes now correctly in bytes. * sysdeps/linux/procsegment.c: Dito. * sysdeps/kernel/procsegment.c: Stack pages are reported via `stack_rss' and no longer count towards `data_rss' * kernel/table.h (table_proc_segment): Added `srs' field. * kernel/table21/module.c (TBL_PROC_SEGMENT): Added kernel support for this. * sysdeps/{linux, kernel, stub}/procmap.c: New files.
* renamed all functions implementing features to '__s'.Martin Baulig1998-05-281-0/+46
* sysdeps/linux/*.c: renamed all functions implementing features to '__s'.