]> git.itanic.dy.fi Git - scan-pagemap/commitdiff
parser: Coding convention fixes
authorTimo Kokkonen <kaapeli@itanic.dy.fi>
Fri, 23 Jul 2010 11:14:03 +0000 (14:14 +0300)
committerTimo Kokkonen <kaapeli@itanic.dy.fi>
Fri, 23 Jul 2010 11:14:03 +0000 (14:14 +0300)
These were reported by the checkpatch.pl script

Signed-off-by: Timo Kokkonen <kaapeli@itanic.dy.fi>
parse.c

diff --git a/parse.c b/parse.c
index 30a84a34a47c95c84274af848330c0e841e0c237..78311d9844cd0faa7553c59588445912631c35af 100644 (file)
--- a/parse.c
+++ b/parse.c
@@ -43,7 +43,7 @@ static struct maps *parse_maps(FILE *file, int pid, int tid)
        char line[1024];
        int ret;
 
-       while(fgets(line, sizeof(line), file)) {
+       while (fgets(line, sizeof(line), file)) {
                struct maps *map = alloc_map();
                unsigned long start, end;
                char name[1024];
@@ -269,11 +269,10 @@ static int parse_pageframe(FILE *file, struct pageframe *pf_tree,
                                list_add(&match->ml->list, &tmp->list);
                        }
 
-                       if (match->page_present) {
+                       if (match->page_present)
                                map->pages_present++;
-                       } else if (match->page_swapped) {
+                       else if (match->page_swapped)
                                map->pages_swapped++;
-                       }
                }
        }
 
@@ -461,7 +460,7 @@ void scan_all_pids(struct pageframe *pf, struct process **process_list,
        if (opts->parse_mask & PARSE_PID)
                read_pageframe_with_threads(opts->pid, pf, process_list, opts);
 
-       while(1) {
+       while (1) {
                pid = get_next_pid(&dir);
                if (pid <= 0)
                        break;