]> git.ipfire.org Git - thirdparty/util-linux.git/commitdiff
dmesg: remove extra space only after time stamp
authorKarel Zak <kzak@redhat.com>
Fri, 2 Sep 2011 12:42:04 +0000 (14:42 +0200)
committerKarel Zak <kzak@redhat.com>
Fri, 2 Sep 2011 12:42:04 +0000 (14:42 +0200)
Signed-off-by: Karel Zak <kzak@redhat.com>
sys-utils/dmesg.c

index 8e7bb4b69f412dc67127963acc30610cff05c432..b3713a0a110e5f86e4a860fa71d4b1ac766d851c 100644 (file)
@@ -480,11 +480,10 @@ static int get_next_record(struct dmesg_control *ctl, struct dmesg_record *rec)
                                                break;
                                }
                        }
+                       if (begin < end && *begin == ' ')
+                               begin++;
                }
 
-               if (begin < end && *begin == ' ')
-                       begin++;
-
                rec->mesg = begin;
                rec->mesg_size = end - begin;