summaryrefslogtreecommitdiffstats
path: root/linux/LinuxProcessList.c
diff options
context:
space:
mode:
authorBenny Baumann <BenBE@geshi.org>2020-10-31 20:39:01 +0100
committerBenny Baumann <BenBE@geshi.org>2020-11-02 22:14:26 +0100
commit0a51eae11fdd741c295d7b0390c6d9dbf04468d8 (patch)
tree0857af69d544bab1995fb0209191e79559a7df25 /linux/LinuxProcessList.c
parent1877325329b282ce59d8d6733b3728913cb2c6b2 (diff)
Spacing after keywords (while)
Diffstat (limited to 'linux/LinuxProcessList.c')
-rw-r--r--linux/LinuxProcessList.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/linux/LinuxProcessList.c b/linux/LinuxProcessList.c
index 577412a9..e500f9dc 100644
--- a/linux/LinuxProcessList.c
+++ b/linux/LinuxProcessList.c
@@ -165,7 +165,7 @@ static int LinuxProcessList_computeCPUcount(void) {
int cpus = 0;
char buffer[PROC_LINE_LENGTH + 1];
- while(fgets(buffer, sizeof(buffer), file)) {
+ while (fgets(buffer, sizeof(buffer), file)) {
if (String_startsWith(buffer, "cpu"))
cpus++;
}
@@ -221,7 +221,7 @@ ProcessList* ProcessList_new(UsersTable* usersTable, Hashtable* pidMatchList, ui
if (statfile == NULL)
CRT_fatalError("Cannot open " PROCSTATFILE);
- while(true) {
+ while (true) {
char buffer[PROC_LINE_LENGTH + 1];
if (fgets(buffer, sizeof(buffer), statfile) == NULL) {
CRT_fatalError("No btime in " PROCSTATFILE);
@@ -498,7 +498,7 @@ static bool LinuxProcessList_readSmapsFile(LinuxProcess* process, const char* di
while (fgets(buffer, sizeof(buffer), f)) {
if(!strchr(buffer, '\n')) {
// Partial line, skip to end of this line
- while(fgets(buffer, sizeof(buffer), f)) {
+ while (fgets(buffer, sizeof(buffer), f)) {
if(strchr(buffer, '\n')) {
break;
}
@@ -542,10 +542,10 @@ static void LinuxProcessList_readOpenVZData(LinuxProcess* process, const char* d
bool foundEnvID = false;
bool foundVPid = false;
char linebuf[256];
- while(fgets(linebuf, sizeof(linebuf), file) != NULL) {
+ while (fgets(linebuf, sizeof(linebuf), file) != NULL) {
if(strchr(linebuf, '\n') == NULL) {
// Partial line, skip to end of this line
- while(fgets(linebuf, sizeof(linebuf), file) != NULL) {
+ while (fgets(linebuf, sizeof(linebuf), file) != NULL) {
if(strchr(linebuf, '\n') != NULL) {
break;
}
@@ -569,11 +569,11 @@ static void LinuxProcessList_readOpenVZData(LinuxProcess* process, const char* d
do {
name_value_sep++;
- } while(*name_value_sep != '\0' && *name_value_sep <= 32);
+ } while (*name_value_sep != '\0' && *name_value_sep <= 32);
char* value_end = name_value_sep;
- while(*value_end != '\0' && *value_end > 32) {
+ while (*value_end != '\0' && *value_end > 32) {
value_end++;
}

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