summaryrefslogtreecommitdiffstats
path: root/Process.h
diff options
context:
space:
mode:
authorHisham Muhammad <hisham@gobolinux.org>2015-03-15 20:29:13 -0300
committerHisham Muhammad <hisham@gobolinux.org>2015-03-15 20:29:13 -0300
commite3fe3962cb493c0f07c3670ce60c008b8712dc8e (patch)
treea3e448f884716fc6655dc9958e3bd3b54882f7de /Process.h
parente7d6eb6a826f76d817d665cbbb41f9172949a539 (diff)
Move more Linux-specific code into Linux subdir.
Diffstat (limited to 'Process.h')
-rw-r--r--Process.h42
1 files changed, 6 insertions, 36 deletions
diff --git a/Process.h b/Process.h
index 38cbaaef..82db228a 100644
--- a/Process.h
+++ b/Process.h
@@ -20,11 +20,7 @@ in the source distribution for its full text.
#include <sys/types.h>
-#define PROCESS_FLAG_IO 1
-#define PROCESS_FLAG_IOPRIO 2
-#define PROCESS_FLAG_OPENVZ 4
-#define PROCESS_FLAG_VSERVER 8
-#define PROCESS_FLAG_CGROUP 16
+#define PROCESS_FLAG_IO 0x0001
#ifndef Process_isKernelThread
#define Process_isKernelThread(_process) (_process->pgrp == 0)
@@ -38,30 +34,7 @@ in the source distribution for its full text.
#define Process_isThread(_process) (Process_isUserlandThread(_process) || Process_isKernelThread(_process))
#endif
-typedef enum ProcessField_ {
- PID = 1, COMM, STATE, PPID, PGRP, SESSION, TTY_NR, TPGID, FLAGS, MINFLT, CMINFLT, MAJFLT, CMAJFLT, UTIME,
- STIME, CUTIME, CSTIME, PRIORITY, NICE, ITREALVALUE, STARTTIME, VSIZE, RSS, RLIM, STARTCODE, ENDCODE,
- STARTSTACK, KSTKESP, KSTKEIP, SIGNAL, BLOCKED, SSIGIGNORE, SIGCATCH, WCHAN, NSWAP, CNSWAP, EXIT_SIGNAL,
- PROCESSOR, M_SIZE, M_RESIDENT, M_SHARE, M_TRS, M_DRS, M_LRS, M_DT, ST_UID, PERCENT_CPU, PERCENT_MEM,
- USER, TIME, NLWP, TGID,
- #ifdef HAVE_OPENVZ
- CTID, VPID,
- #endif
- #ifdef HAVE_VSERVER
- VXID,
- #endif
- #ifdef HAVE_TASKSTATS
- RCHAR, WCHAR, SYSCR, SYSCW, RBYTES, WBYTES, CNCLWB, IO_READ_RATE, IO_WRITE_RATE, IO_RATE,
- #endif
- #ifdef HAVE_CGROUP
- CGROUP,
- #endif
- #ifdef HAVE_OOM
- OOM,
- #endif
- IO_PRIORITY,
- LAST_PROCESSFIELD
-} ProcessField;
+typedef int ProcessField;
typedef struct Process_ {
Object super;
@@ -71,6 +44,10 @@ typedef struct Process_ {
pid_t pid;
char* comm;
int indent;
+
+ int basenameOffset;
+ bool updated;
+
char state;
bool tag;
bool showChildren;
@@ -137,8 +114,6 @@ typedef struct Process_ {
#endif
int exit_signal;
- int basenameOffset;
- bool updated;
unsigned long int minflt;
unsigned long int cminflt;
@@ -176,11 +151,6 @@ void Process_writeField(Process* this, RichString* str, ProcessField field);
long Process_compare(const void* v1, const void* v2);
-extern ProcessFieldData Process_fields[];
-
-
-void Process_setupColumnWidths();
-
#define ONE_K 1024L
#define ONE_M (ONE_K * ONE_K)
#define ONE_G (ONE_M * ONE_K)

© 2014-2024 Faster IT GmbH | imprint | privacy policy