summaryrefslogtreecommitdiff
path: root/src/bootchart
diff options
context:
space:
mode:
authorDaniel Mack <github@zonque.org>2015-09-09 15:12:28 +0200
committerDaniel Mack <github@zonque.org>2015-09-09 15:12:28 +0200
commitd7acddde057d25a4fb7835943ef3c73f262ba54f (patch)
treecb6e0ab245a4ed43f1367b8164b8022f0e77fc13 /src/bootchart
parent02736a9abce02eb53b0d504f96fc7b3e4f077020 (diff)
parent57255510c95ca3369d241502f26d7bbd8fac30a6 (diff)
Merge pull request #1216 from poettering/coccinelle-fixes-2
Coccinelle fixes 2
Diffstat (limited to 'src/bootchart')
-rw-r--r--src/bootchart/bootchart.c3
-rw-r--r--src/bootchart/svg.c2
2 files changed, 2 insertions, 3 deletions
diff --git a/src/bootchart/bootchart.c b/src/bootchart/bootchart.c
index e61b58b5e5..b4047b0d14 100644
--- a/src/bootchart/bootchart.c
+++ b/src/bootchart/bootchart.c
@@ -338,10 +338,9 @@ int main(int argc, char *argv[]) {
* - child logs data
*/
if (getpid() == 1) {
- if (fork()) {
+ if (fork())
/* parent */
execl(arg_init_path, arg_init_path, NULL);
- }
}
argv[0][0] = '@';
diff --git a/src/bootchart/svg.c b/src/bootchart/svg.c
index 1231e6eace..c66f12e3a6 100644
--- a/src/bootchart/svg.c
+++ b/src/bootchart/svg.c
@@ -888,7 +888,7 @@ static struct ps_struct *get_next_ps(struct ps_struct *ps, struct ps_struct *ps_
return ps->next;
/* go back for parent siblings */
- while (1) {
+ for (;;) {
if (ps->parent && ps->parent->next)
return ps->parent->next;