aboutsummaryrefslogtreecommitdiffstats
path: root/src/firemon
diff options
context:
space:
mode:
authorLibravatar Kelvin M. Klann <kmk3.code@protonmail.com>2023-02-19 14:26:15 -0300
committerLibravatar Kelvin M. Klann <kmk3.code@protonmail.com>2023-02-20 17:39:31 -0300
commit490051f71494e828f2020257c012c3b28398d852 (patch)
treee565f37c36d9573dd9d95c2028361012f1132989 /src/firemon
parent.gitattributes: mark some binary files as such (diff)
downloadfirejail-490051f71494e828f2020257c012c3b28398d852.tar.gz
firejail-490051f71494e828f2020257c012c3b28398d852.tar.zst
firejail-490051f71494e828f2020257c012c3b28398d852.zip
Fix space before/after tab in indent
This fixes all of the "space before tab in indent" errors raised by git: $ git diff --check 4b825dc642cb6eb9a060e54bf8d69288fbee4904..HEAD | grep '^[^+]' | cut -f 3 -d : | LC_ALL=C sort | uniq -c 72 space before tab in indent. Commands used to find the errors: $ git diff --check 4b825dc642cb6eb9a060e54bf8d69288fbee4904..HEAD $ git grep -In "$(printf '\t') " Note: Unlike "space before tab in indent", the reverse ("space after tab in indent") is not reported by git. That is because spaces could be intentionally used for alignment or line continuation, but in some cases they are being used for indentation together with tabs and in others the formatting is misaligned. The second command was used to help find and fix these other issues.
Diffstat (limited to 'src/firemon')
-rw-r--r--src/firemon/procevent.c2
-rw-r--r--src/firemon/top.c3
2 files changed, 3 insertions, 2 deletions
diff --git a/src/firemon/procevent.c b/src/firemon/procevent.c
index ff4fdda56..77739c1f3 100644
--- a/src/firemon/procevent.c
+++ b/src/firemon/procevent.c
@@ -309,7 +309,7 @@ static void __attribute__((noreturn)) procevent_monitor(const int sock, pid_t my
309#endif 309#endif
310 if (proc_ev->event_data.fork.child_pid != 310 if (proc_ev->event_data.fork.child_pid !=
311 proc_ev->event_data.fork.child_tgid) 311 proc_ev->event_data.fork.child_tgid)
312 continue; // this is a thread, not a process 312 continue; // this is a thread, not a process
313 pid = proc_ev->event_data.fork.parent_tgid; 313 pid = proc_ev->event_data.fork.parent_tgid;
314#ifdef DEBUG_PRCTL 314#ifdef DEBUG_PRCTL
315 printf("%s: %d, event fork, pid %d\n", __FUNCTION__, __LINE__, pid); 315 printf("%s: %d, event fork, pid %d\n", __FUNCTION__, __LINE__, pid);
diff --git a/src/firemon/top.c b/src/firemon/top.c
index c127e2f56..c70bc9424 100644
--- a/src/firemon/top.c
+++ b/src/firemon/top.c
@@ -166,7 +166,8 @@ static char *print_top(unsigned index, unsigned parent, unsigned *utime, unsigne
166 snprintf(prcs_str, 10, "%d", *cnt); 166 snprintf(prcs_str, 10, "%d", *cnt);
167 167
168 if (asprintf(&rv, "%-7.7s %-9.9s %-8.8s %-8.8s %-5.5s %-4.4s %-9.9s %s", 168 if (asprintf(&rv, "%-7.7s %-9.9s %-8.8s %-8.8s %-5.5s %-4.4s %-9.9s %s",
169 pidstr, ptruser, rss, shared, cpu_str, prcs_str, uptime_str, ptrcmd) == -1) 169 pidstr, ptruser, rss, shared, cpu_str, prcs_str,
170 uptime_str, ptrcmd) == -1)
170 errExit("asprintf"); 171 errExit("asprintf");
171 172
172 if (cmd) 173 if (cmd)