summaryrefslogtreecommitdiffstats
path: root/linux/LinuxProcessList.h
diff options
context:
space:
mode:
authorHisham Muhammad <hisham@gobolinux.org>2015-12-14 13:27:11 -0200
committerHisham Muhammad <hisham@gobolinux.org>2015-12-14 13:27:11 -0200
commit802e216870efb740069583b208fa4bac970653e0 (patch)
treefc30de8f1eff8ed55fd664f00a93914caf567dc5 /linux/LinuxProcessList.h
parentcccc18dd2f820c3eba3a495eb2265d682c77d718 (diff)
Extend buffer for reading lines from /proc.
Apparently a line longer than 255 chars was spotted in the wild: http://serverfault.com/questions/577939/linux-ps-htop-show-processes-running-for-hundreds-or-thousands-of-days-though-h#comment676098_577939
Diffstat (limited to 'linux/LinuxProcessList.h')
-rw-r--r--linux/LinuxProcessList.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/linux/LinuxProcessList.h b/linux/LinuxProcessList.h
index 538d98cb..2a4abff9 100644
--- a/linux/LinuxProcessList.h
+++ b/linux/LinuxProcessList.h
@@ -59,6 +59,10 @@ typedef struct LinuxProcessList_ {
#define PROCMEMINFOFILE PROCDIR "/meminfo"
#endif
+#ifndef PROC_LINE_LENGTH
+#define PROC_LINE_LENGTH 512
+#endif
+
ProcessList* ProcessList_new(UsersTable* usersTable, Hashtable* pidWhiteList, uid_t userId);

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