Compare commits
17 Commits
LIBGTOP_2_
...
2.33.4
Author | SHA1 | Date | |
---|---|---|---|
|
819bfe56ee | ||
|
de408a6bba | ||
|
05cb14dbb2 | ||
|
7e3e4b6860 | ||
|
02070b7170 | ||
|
fcfacf3213 | ||
|
7925f83b57 | ||
|
68104bdde1 | ||
|
ac2aef0f47 | ||
|
9764518807 | ||
|
13f08cf164 | ||
|
c8a4c3d2a1 | ||
|
52c35c1b81 | ||
|
e528a7280b | ||
|
99ff3d4dff | ||
|
f865e95e20 | ||
|
eec96d8ae8 |
24
NEWS
24
NEWS
@@ -1,3 +1,27 @@
|
|||||||
|
18 January 2016: Overview of changes in 2.33.4
|
||||||
|
|
||||||
|
* On OpenBSD only PID 1 is special
|
||||||
|
* Call setlocale in main
|
||||||
|
|
||||||
|
14 December: Overview of changes in 2.33.3
|
||||||
|
|
||||||
|
* Fixed borken compilation on OpenBSD
|
||||||
|
* Updated translations.
|
||||||
|
|
||||||
|
21 September 2015: Overview of changes in 2.32.0
|
||||||
|
|
||||||
|
* Stable release
|
||||||
|
|
||||||
|
14 September 2015: Overview of changes in 2.31.91
|
||||||
|
================================================
|
||||||
|
* Darwin:
|
||||||
|
- Fixed build.
|
||||||
|
|
||||||
|
* All
|
||||||
|
- GI docs fixes
|
||||||
|
- include fixes
|
||||||
|
- Updated translations
|
||||||
|
|
||||||
16 August 2015: Overview of changes in 2.31.90
|
16 August 2015: Overview of changes in 2.31.90
|
||||||
=============================================
|
=============================================
|
||||||
* ABI changes:
|
* ABI changes:
|
||||||
|
@@ -3,8 +3,8 @@ dnl Configure script for the Gnome library
|
|||||||
dnl
|
dnl
|
||||||
|
|
||||||
m4_define([libgtop_major_version], [2])
|
m4_define([libgtop_major_version], [2])
|
||||||
m4_define([libgtop_minor_version], [31])
|
m4_define([libgtop_minor_version], [33])
|
||||||
m4_define([libgtop_micro_version], [90])
|
m4_define([libgtop_micro_version], [4])
|
||||||
m4_define([libgtop_version], [libgtop_major_version.libgtop_minor_version.libgtop_micro_version])
|
m4_define([libgtop_version], [libgtop_major_version.libgtop_minor_version.libgtop_micro_version])
|
||||||
|
|
||||||
dnl increment if the interface has additions, changes, removals.
|
dnl increment if the interface has additions, changes, removals.
|
||||||
|
@@ -2,7 +2,7 @@ glibtopdir = $(includedir)/libgtop-2.0/glibtop
|
|||||||
|
|
||||||
glibtop_HEADERS = close.h loadavg.h prockernel.h procstate.h \
|
glibtop_HEADERS = close.h loadavg.h prockernel.h procstate.h \
|
||||||
sem_limits.h uptime.h command.h mem.h proclist.h \
|
sem_limits.h uptime.h command.h mem.h proclist.h \
|
||||||
proctime.h shm_limits.h version.h cpu.h msg_limits.h \
|
proctime.h shm_limits.h cpu.h msg_limits.h \
|
||||||
procmem.h procuid.h swap.h \
|
procmem.h procuid.h swap.h \
|
||||||
procsegment.h sysdeps.h global.h \
|
procsegment.h sysdeps.h global.h \
|
||||||
procsignal.h union.h gnuserv.h \
|
procsignal.h union.h gnuserv.h \
|
||||||
@@ -11,4 +11,6 @@ glibtop_HEADERS = close.h loadavg.h prockernel.h procstate.h \
|
|||||||
procwd.h procaffinity.h \
|
procwd.h procaffinity.h \
|
||||||
netlist.h procopenfiles.h open.h
|
netlist.h procopenfiles.h open.h
|
||||||
|
|
||||||
noinst_HEADERS = error.h write.h read_data.h read.h init_hooks.h machine.h
|
noinst_HEADERS = error.h write.h read_data.h read.h init_hooks.h machine.h \
|
||||||
|
version.h
|
||||||
|
|
||||||
|
@@ -55,7 +55,7 @@ struct _glibtop_mountlist
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* glibtop_get_mountlist:
|
* glibtop_get_mountlist:
|
||||||
* @buf: (out):
|
* @buf:
|
||||||
* @all_fs:
|
* @all_fs:
|
||||||
*
|
*
|
||||||
* Returns: (transfer full):
|
* Returns: (transfer full):
|
||||||
|
@@ -29,6 +29,7 @@ typedef struct _glibtop_proc_affinity glibtop_proc_affinity;
|
|||||||
|
|
||||||
#define GLIBTOP_PROC_AFFINITY_NUMBER 0
|
#define GLIBTOP_PROC_AFFINITY_NUMBER 0
|
||||||
#define GLIBTOP_PROC_AFFINITY_ALL 1
|
#define GLIBTOP_PROC_AFFINITY_ALL 1
|
||||||
|
#define GLIBTOP_MAX_PROC_AFFINITY 2
|
||||||
|
|
||||||
struct _glibtop_proc_affinity
|
struct _glibtop_proc_affinity
|
||||||
{
|
{
|
||||||
|
@@ -79,6 +79,15 @@ char **
|
|||||||
glibtop_get_proc_argv_l (glibtop *server, glibtop_proc_args *buf,
|
glibtop_get_proc_argv_l (glibtop *server, glibtop_proc_args *buf,
|
||||||
pid_t pid, unsigned max_len);
|
pid_t pid, unsigned max_len);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* glibtop_get_proc_argv:
|
||||||
|
* @buf:
|
||||||
|
* @pid:
|
||||||
|
* @max_len:
|
||||||
|
*
|
||||||
|
* Returns: (transfer full):
|
||||||
|
*/
|
||||||
|
|
||||||
char **
|
char **
|
||||||
glibtop_get_proc_argv (glibtop_proc_args *buf, pid_t pid, unsigned max_len);
|
glibtop_get_proc_argv (glibtop_proc_args *buf, pid_t pid, unsigned max_len);
|
||||||
|
|
||||||
|
@@ -92,17 +92,18 @@ struct _glibtop_proc_map
|
|||||||
guint64 total; /* GLIBTOP_PROC_MAP_TOTAL */
|
guint64 total; /* GLIBTOP_PROC_MAP_TOTAL */
|
||||||
guint64 size; /* GLIBTOP_PROC_MAP_SIZE */
|
guint64 size; /* GLIBTOP_PROC_MAP_SIZE */
|
||||||
};
|
};
|
||||||
glibtop_map_entry *
|
|
||||||
glibtop_get_proc_map(glibtop_proc_map *buf, pid_t pid);
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* glibtop_get_proc_map:
|
* glibtop_get_proc_map:
|
||||||
* @buf: (out):
|
* @buf:
|
||||||
* @pid:
|
* @pid:
|
||||||
*
|
*
|
||||||
* Returns: (transfer none):
|
* Returns: (transfer none):
|
||||||
*/
|
*/
|
||||||
|
glibtop_map_entry *
|
||||||
|
glibtop_get_proc_map(glibtop_proc_map *buf, pid_t pid);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* glibtop_get_proc_map_l:
|
* glibtop_get_proc_map_l:
|
||||||
|
@@ -53,6 +53,12 @@ struct _glibtop_proc_mem
|
|||||||
* of the process; usually 2,147,483,647 */
|
* of the process; usually 2,147,483,647 */
|
||||||
};
|
};
|
||||||
|
|
||||||
|
/**
|
||||||
|
* glibtop_get_proc_map:
|
||||||
|
* @buf:
|
||||||
|
* @pid:
|
||||||
|
*
|
||||||
|
*/
|
||||||
void glibtop_get_proc_mem(glibtop_proc_mem *buf, pid_t pid);
|
void glibtop_get_proc_mem(glibtop_proc_mem *buf, pid_t pid);
|
||||||
|
|
||||||
#if GLIBTOP_SUID_PROC_MEM
|
#if GLIBTOP_SUID_PROC_MEM
|
||||||
|
@@ -96,7 +96,7 @@ struct _glibtop_proc_open_files
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* glibtop_get_proc_open_files:
|
* glibtop_get_proc_open_files:
|
||||||
* @buf: (out):
|
* @buf:
|
||||||
* @pid:
|
* @pid:
|
||||||
*
|
*
|
||||||
* Returns: (transfer none):
|
* Returns: (transfer none):
|
||||||
|
@@ -30,7 +30,7 @@ typedef struct _glibtop_proc_wd glibtop_proc_wd;
|
|||||||
#define GLIBTOP_PROC_WD_NUMBER 0
|
#define GLIBTOP_PROC_WD_NUMBER 0
|
||||||
#define GLIBTOP_PROC_WD_ROOT 1
|
#define GLIBTOP_PROC_WD_ROOT 1
|
||||||
#define GLIBTOP_PROC_WD_EXE 2
|
#define GLIBTOP_PROC_WD_EXE 2
|
||||||
#define GLIBTOP_PROC_WD_MAX 3
|
#define GLIBTOP_MAX_PROC_WD 3
|
||||||
|
|
||||||
#define GLIBTOP_PROC_WD_ROOT_LEN 215
|
#define GLIBTOP_PROC_WD_ROOT_LEN 215
|
||||||
#define GLIBTOP_PROC_WD_EXE_LEN 215
|
#define GLIBTOP_PROC_WD_EXE_LEN 215
|
||||||
@@ -44,6 +44,13 @@ struct _glibtop_proc_wd
|
|||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* glibtop_get_proc_wd:
|
||||||
|
* @buf:
|
||||||
|
* @pid:
|
||||||
|
*
|
||||||
|
* Returns: (transfer full):
|
||||||
|
*/
|
||||||
char ** glibtop_get_proc_wd(glibtop_proc_wd *buf, pid_t pid);
|
char ** glibtop_get_proc_wd(glibtop_proc_wd *buf, pid_t pid);
|
||||||
char ** glibtop_get_proc_wd_l(glibtop *server, glibtop_proc_wd *buf, pid_t pid);
|
char ** glibtop_get_proc_wd_l(glibtop *server, glibtop_proc_wd *buf, pid_t pid);
|
||||||
|
|
||||||
|
@@ -26,10 +26,10 @@ INTROSPECTION_SCANNER_ARGS = --accept-unprefixed --warn-all
|
|||||||
INTROSPECTION_COMPILER_ARGS =
|
INTROSPECTION_COMPILER_ARGS =
|
||||||
|
|
||||||
if HAVE_INTROSPECTION
|
if HAVE_INTROSPECTION
|
||||||
introspection_sources = $(libgtop_2_0_la_SOURCES) lib.c ../glibtop.h \
|
introspection_sources = $(libgtop_2_0_la_SOURCES) lib.c ../glibtop.h ../libgtopconfig.h \
|
||||||
../include/glibtop/close.h ../include/glibtop/loadavg.h ../include/glibtop/prockernel.h ../include/glibtop/procstate.h \
|
../include/glibtop/close.h ../include/glibtop/loadavg.h ../include/glibtop/prockernel.h ../include/glibtop/procstate.h \
|
||||||
../include/glibtop/sem_limits.h ../include/glibtop/uptime.h ../include/glibtop/command.h ../include/glibtop/mem.h ../include/glibtop/proclist.h \
|
../include/glibtop/sem_limits.h ../include/glibtop/uptime.h ../include/glibtop/command.h ../include/glibtop/mem.h ../include/glibtop/proclist.h \
|
||||||
../include/glibtop/proctime.h ../include/glibtop/shm_limits.h ../include/glibtop/version.h ../include/glibtop/cpu.h ../include/glibtop/msg_limits.h \
|
../include/glibtop/proctime.h ../include/glibtop/shm_limits.h ../include/glibtop/cpu.h ../include/glibtop/msg_limits.h \
|
||||||
../include/glibtop/procmem.h ../include/glibtop/procuid.h ../include/glibtop/swap.h \
|
../include/glibtop/procmem.h ../include/glibtop/procuid.h ../include/glibtop/swap.h \
|
||||||
../include/glibtop/procsegment.h ../include/glibtop/sysdeps.h ../include/glibtop/global.h \
|
../include/glibtop/procsegment.h ../include/glibtop/sysdeps.h ../include/glibtop/global.h \
|
||||||
../include/glibtop/procsignal.h ../include/glibtop/union.h ../include/glibtop/gnuserv.h \
|
../include/glibtop/procsignal.h ../include/glibtop/union.h ../include/glibtop/gnuserv.h \
|
||||||
|
27
po/oc.po
27
po/oc.po
@@ -1,25 +1,23 @@
|
|||||||
# Occitan translation of libgtop.
|
# Occitan translation of libgtop.
|
||||||
# Copyright (C) 1998-2004 Free Software Foundation, Inc.
|
# Copyright (C) 1998-2004 Free Software Foundation, Inc.
|
||||||
# This file is distributed under the GNU General Public License Version 2.
|
# This file is distributed under the GNU General Public License Version 2.
|
||||||
#
|
# Cédric Valmary <cvalmary@yahoo.fr>, 2015.
|
||||||
#
|
# Cédric Valmary (Tot en òc) <cvalmary@yahoo.fr>, 2015.
|
||||||
#
|
|
||||||
# Cédric Valmary (Tot en Òc) <cvalmary@yahoo.fr>, 2015.
|
|
||||||
msgid ""
|
msgid ""
|
||||||
msgstr ""
|
msgstr ""
|
||||||
"Project-Id-Version: libgtop 2.9.91\n"
|
"Project-Id-Version: libgtop 2.9.91\n"
|
||||||
"Report-Msgid-Bugs-To: http://bugzilla.gnome.org/enter_bug.cgi?product=libgto"
|
"Report-Msgid-Bugs-To: http://bugzilla.gnome.org/enter_bug.cgi?product=libgtop"
|
||||||
"p&keywords=I18N+L10N&component=general\n"
|
"&keywords=I18N+L10N&component=general\n"
|
||||||
"POT-Creation-Date: 2013-12-19 14:39+0000\n"
|
"POT-Creation-Date: 2015-04-30 07:47+0000\n"
|
||||||
"PO-Revision-Date: 2015-04-30 09:46+0200\n"
|
"PO-Revision-Date: 2015-10-31 08:15+0200\n"
|
||||||
"Last-Translator: Cédric Valmary (Tot en Òc) <cvalmary@yahoo.fr>\n"
|
"Last-Translator: Cédric Valmary (Tot en òc) <cvalmary@yahoo.fr>\n"
|
||||||
"Language-Team: www.totenoc.eu\n"
|
"Language-Team: Tot en òc (totenoc.eu)\n"
|
||||||
"Language: oc\n"
|
"Language: oc\n"
|
||||||
"MIME-Version: 1.0\n"
|
"MIME-Version: 1.0\n"
|
||||||
"Content-Type: text/plain; charset=UTF-8\n"
|
"Content-Type: text/plain; charset=UTF-8\n"
|
||||||
"Content-Transfer-Encoding: 8bit\n"
|
"Content-Transfer-Encoding: 8bit\n"
|
||||||
"Plural-Forms: nplurals=2; plural=(n > 1);\n"
|
"Plural-Forms: nplurals=2; plural=(n > 1);\n"
|
||||||
"X-Generator: Virtaal 0.7.0\n"
|
"X-Generator: Virtaal 0.7.1\n"
|
||||||
"X-Project-Style: gnome\n"
|
"X-Project-Style: gnome\n"
|
||||||
|
|
||||||
#: ../lib/read.c:51
|
#: ../lib/read.c:51
|
||||||
@@ -53,7 +51,7 @@ msgstr "Activa lo desbugatge"
|
|||||||
|
|
||||||
#: ../src/daemon/gnuserv.c:457
|
#: ../src/daemon/gnuserv.c:457
|
||||||
msgid "Enable verbose output"
|
msgid "Enable verbose output"
|
||||||
msgstr "Activa la sortida charraira"
|
msgstr "Activa la sortida verbosa"
|
||||||
|
|
||||||
#: ../src/daemon/gnuserv.c:459
|
#: ../src/daemon/gnuserv.c:459
|
||||||
msgid "Don't fork into background"
|
msgid "Don't fork into background"
|
||||||
@@ -61,12 +59,13 @@ msgstr "Aviar pas en prètzfach de fons"
|
|||||||
|
|
||||||
#: ../src/daemon/gnuserv.c:461
|
#: ../src/daemon/gnuserv.c:461
|
||||||
msgid "Invoked from inetd"
|
msgid "Invoked from inetd"
|
||||||
msgstr "Invocat a partir de inetd"
|
msgstr "Invocat a partir d'inetd"
|
||||||
|
|
||||||
#: ../src/daemon/gnuserv.c:495
|
#: ../src/daemon/gnuserv.c:495
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "Run '%s --help' to see a full list of available command line options.\n"
|
msgid "Run '%s --help' to see a full list of available command line options.\n"
|
||||||
msgstr "Aviar « %s --help » per afichar la lista de las opcions de la linha de "
|
msgstr ""
|
||||||
|
"Aviar « %s --help » per afichar la lista de las opcions de la linha de "
|
||||||
"comanda.\n"
|
"comanda.\n"
|
||||||
|
|
||||||
#: ../sysdeps/osf1/siglist.c:27 ../sysdeps/sun4/siglist.c:27
|
#: ../sysdeps/osf1/siglist.c:27 ../sysdeps/sun4/siglist.c:27
|
||||||
|
18
po/pl.po
18
po/pl.po
@@ -6,14 +6,14 @@
|
|||||||
# -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
|
# -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
|
||||||
# Zbigniew Chyla <chyla@alice.ci.pwr.wroc.pl>, 1999-2002.
|
# Zbigniew Chyla <chyla@alice.ci.pwr.wroc.pl>, 1999-2002.
|
||||||
# Artur Flinta <aflinta@at.kernel.pl>, 2004-2007.
|
# Artur Flinta <aflinta@at.kernel.pl>, 2004-2007.
|
||||||
# Piotr Drąg <piotrdrag@gmail.com>, 2010-2012.
|
# Piotr Drąg <piotrdrag@gmail.com>, 2010-2015.
|
||||||
# Aviary.pl <gnomepl@aviary.pl>, 2010-2012.
|
# Aviary.pl <gnomepl@aviary.pl>, 2010-2015.
|
||||||
msgid ""
|
msgid ""
|
||||||
msgstr ""
|
msgstr ""
|
||||||
"Project-Id-Version: libgtop\n"
|
"Project-Id-Version: libgtop\n"
|
||||||
"Report-Msgid-Bugs-To: \n"
|
"Report-Msgid-Bugs-To: \n"
|
||||||
"POT-Creation-Date: 2012-09-04 18:37+0200\n"
|
"POT-Creation-Date: 2015-08-26 19:45+0200\n"
|
||||||
"PO-Revision-Date: 2012-09-04 18:42+0200\n"
|
"PO-Revision-Date: 2015-08-26 19:47+0200\n"
|
||||||
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
|
"Last-Translator: Piotr Drąg <piotrdrag@gmail.com>\n"
|
||||||
"Language-Team: Polish <gnomepl@aviary.pl>\n"
|
"Language-Team: Polish <gnomepl@aviary.pl>\n"
|
||||||
"Language: pl\n"
|
"Language: pl\n"
|
||||||
@@ -25,7 +25,7 @@ msgstr ""
|
|||||||
"X-Poedit-Language: Polish\n"
|
"X-Poedit-Language: Polish\n"
|
||||||
"X-Poedit-Country: Poland\n"
|
"X-Poedit-Country: Poland\n"
|
||||||
|
|
||||||
#: ../lib/read.c:51
|
#: ../lib/read.c:49
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "read %d byte"
|
msgid "read %d byte"
|
||||||
msgid_plural "read %d bytes"
|
msgid_plural "read %d bytes"
|
||||||
@@ -33,11 +33,11 @@ msgstr[0] "odczyt %d bajtu"
|
|||||||
msgstr[1] "odczyt %d bajtów"
|
msgstr[1] "odczyt %d bajtów"
|
||||||
msgstr[2] "odczyt %d bajtów"
|
msgstr[2] "odczyt %d bajtów"
|
||||||
|
|
||||||
#: ../lib/read_data.c:51
|
#: ../lib/read_data.c:49
|
||||||
msgid "read data size"
|
msgid "read data size"
|
||||||
msgstr "odczyt rozmiaru danych"
|
msgstr "odczyt rozmiaru danych"
|
||||||
|
|
||||||
#: ../lib/read_data.c:70
|
#: ../lib/read_data.c:66
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "read %lu byte of data"
|
msgid "read %lu byte of data"
|
||||||
msgid_plural "read %lu bytes of data"
|
msgid_plural "read %lu bytes of data"
|
||||||
@@ -45,7 +45,7 @@ msgstr[0] "odczytano jeden bajt danych"
|
|||||||
msgstr[1] "odczytano %lu bajty danych"
|
msgstr[1] "odczytano %lu bajty danych"
|
||||||
msgstr[2] "odczytano %lu bajtów danych"
|
msgstr[2] "odczytano %lu bajtów danych"
|
||||||
|
|
||||||
#: ../lib/write.c:51
|
#: ../lib/write.c:49
|
||||||
#, c-format
|
#, c-format
|
||||||
msgid "wrote %d byte"
|
msgid "wrote %d byte"
|
||||||
msgid_plural "wrote %d bytes"
|
msgid_plural "wrote %d bytes"
|
||||||
@@ -73,7 +73,7 @@ msgstr "Wywołanie przez inetd"
|
|||||||
#, c-format
|
#, c-format
|
||||||
msgid "Run '%s --help' to see a full list of available command line options.\n"
|
msgid "Run '%s --help' to see a full list of available command line options.\n"
|
||||||
msgstr ""
|
msgstr ""
|
||||||
"Polecenie \"%s --help\" wyświetli pełną listę dostępnych opcji wiersza "
|
"Polecenie „%s --help” wyświetli pełną listę dostępnych opcji wiersza "
|
||||||
"poleceń.\n"
|
"poleceń.\n"
|
||||||
|
|
||||||
#: ../sysdeps/osf1/siglist.c:27 ../sysdeps/sun4/siglist.c:27
|
#: ../sysdeps/osf1/siglist.c:27 ../sysdeps/sun4/siglist.c:27
|
||||||
|
@@ -43,6 +43,7 @@
|
|||||||
#include <glibtop/gnuserv.h>
|
#include <glibtop/gnuserv.h>
|
||||||
|
|
||||||
#include <errno.h>
|
#include <errno.h>
|
||||||
|
#include <locale.h>
|
||||||
|
|
||||||
#include "daemon.h"
|
#include "daemon.h"
|
||||||
|
|
||||||
@@ -473,6 +474,8 @@ main (int argc, char **argv)
|
|||||||
|
|
||||||
int ils = -1; /* internet domain listen socket */
|
int ils = -1; /* internet domain listen socket */
|
||||||
|
|
||||||
|
setlocale (LC_ALL, "");
|
||||||
|
|
||||||
/* On non-glibc systems, this is not set up for us. */
|
/* On non-glibc systems, this is not set up for us. */
|
||||||
if (!program_invocation_name) {
|
if (!program_invocation_name) {
|
||||||
char *arg;
|
char *arg;
|
||||||
|
@@ -22,6 +22,8 @@
|
|||||||
|
|
||||||
G_BEGIN_DECLS
|
G_BEGIN_DECLS
|
||||||
|
|
||||||
|
#include <glibtop_machine.h>
|
||||||
|
|
||||||
static inline void glibtop_suid_enter (glibtop *server) {
|
static inline void glibtop_suid_enter (glibtop *server) {
|
||||||
setreuid (server->machine->uid, server->machine->euid);
|
setreuid (server->machine->uid, server->machine->euid);
|
||||||
};
|
};
|
||||||
|
@@ -23,6 +23,8 @@
|
|||||||
#include <glibtop/cpu.h>
|
#include <glibtop/cpu.h>
|
||||||
#include <glibtop/open.h>
|
#include <glibtop/open.h>
|
||||||
|
|
||||||
|
#include <glibtop_machine.h>
|
||||||
|
|
||||||
#include <mach/mach_host.h>
|
#include <mach/mach_host.h>
|
||||||
#include <mach/mach_init.h>
|
#include <mach/mach_init.h>
|
||||||
#include <mach/mach_interface.h>
|
#include <mach/mach_interface.h>
|
||||||
|
@@ -28,6 +28,8 @@ G_BEGIN_DECLS
|
|||||||
#include <sys/param.h>
|
#include <sys/param.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#include <glibtop_machine.h>
|
||||||
|
|
||||||
#define KI_PROC(ki) (&(ki))->kp_proc)
|
#define KI_PROC(ki) (&(ki))->kp_proc)
|
||||||
#define KI_EPROC(ki) (&(ki))->kp_eproc)
|
#define KI_EPROC(ki) (&(ki))->kp_eproc)
|
||||||
|
|
||||||
|
@@ -21,6 +21,7 @@
|
|||||||
|
|
||||||
#include <config.h>
|
#include <config.h>
|
||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
|
#include <sys/sysctl.h>
|
||||||
#include <glibtop.h>
|
#include <glibtop.h>
|
||||||
#include <glibtop/open.h>
|
#include <glibtop/open.h>
|
||||||
#include <glibtop/cpu.h>
|
#include <glibtop/cpu.h>
|
||||||
|
@@ -56,11 +56,8 @@ glibtop_get_proc_args_p (glibtop *server, glibtop_proc_args *buf,
|
|||||||
|
|
||||||
memset (buf, 0, sizeof (glibtop_proc_args));
|
memset (buf, 0, sizeof (glibtop_proc_args));
|
||||||
|
|
||||||
/*
|
/* Ignore init */
|
||||||
* Don't bother with PIDs below 20, because everything below this
|
if (pid < 2) return NULL;
|
||||||
* number is highly likely to be a kernel thread.
|
|
||||||
*/
|
|
||||||
if (pid < 19) return NULL;
|
|
||||||
|
|
||||||
glibtop_suid_enter (server);
|
glibtop_suid_enter (server);
|
||||||
|
|
||||||
|
@@ -284,7 +284,7 @@ glibtop_get_proc_map_p (glibtop *server, glibtop_proc_map *buf,
|
|||||||
mentry->perm |= GLIBTOP_MAP_PERM_READ;
|
mentry->perm |= GLIBTOP_MAP_PERM_READ;
|
||||||
if (entry->protection & PROT_WRITE)
|
if (entry->protection & PROT_WRITE)
|
||||||
mentry->perm |= GLIBTOP_MAP_PERM_WRITE;
|
mentry->perm |= GLIBTOP_MAP_PERM_WRITE;
|
||||||
if (entry->protection & PROT_EXECUTE)
|
if (entry->protection & PROT_EXEC)
|
||||||
mentry->perm |= GLIBTOP_MAP_PERM_EXECUTE;
|
mentry->perm |= GLIBTOP_MAP_PERM_EXECUTE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -42,6 +42,7 @@
|
|||||||
#include <arpa/inet.h>
|
#include <arpa/inet.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
|
#include <kvm.h>
|
||||||
|
|
||||||
#include "glibtop_private.h"
|
#include "glibtop_private.h"
|
||||||
|
|
||||||
|
@@ -25,7 +25,10 @@
|
|||||||
#include <glibtop/cpu.h>
|
#include <glibtop/cpu.h>
|
||||||
#include <glibtop/open.h>
|
#include <glibtop/open.h>
|
||||||
#include <glibtop/init_hooks.h>
|
#include <glibtop/init_hooks.h>
|
||||||
|
#include <glibtop/machine.h>
|
||||||
|
|
||||||
|
#include <fcntl.h>
|
||||||
|
#include <kvm.h>
|
||||||
|
|
||||||
/* !!! THIS FUNCTION RUNS SUID ROOT - CHANGE WITH CAUTION !!! */
|
/* !!! THIS FUNCTION RUNS SUID ROOT - CHANGE WITH CAUTION !!! */
|
||||||
|
|
||||||
|
@@ -26,6 +26,8 @@
|
|||||||
|
|
||||||
#include <glibtop/cpu.h>
|
#include <glibtop/cpu.h>
|
||||||
|
|
||||||
|
#include <sys/sysctl.h>
|
||||||
|
|
||||||
static const unsigned long _glibtop_sysdeps_uptime =
|
static const unsigned long _glibtop_sysdeps_uptime =
|
||||||
(1L << GLIBTOP_UPTIME_UPTIME) + (1L << GLIBTOP_UPTIME_IDLETIME) +
|
(1L << GLIBTOP_UPTIME_UPTIME) + (1L << GLIBTOP_UPTIME_IDLETIME) +
|
||||||
(1UL << GLIBTOP_UPTIME_BOOT_TIME);
|
(1UL << GLIBTOP_UPTIME_BOOT_TIME);
|
||||||
|
Reference in New Issue
Block a user