]> err.no Git - systemd/commitdiff
[PATCH] check for empty line a bit better in the parser.
authorgreg@kroah.com <greg@kroah.com>
Thu, 25 Dec 2003 05:48:18 +0000 (21:48 -0800)
committerGreg KH <gregkh@suse.de>
Wed, 27 Apr 2005 04:13:10 +0000 (21:13 -0700)
Thanks to Mitch <mitch@0bits.com> for pointing this out.

namedev_parse.c

index 266fa35a1945939ab5f384d70980dfcd3b2c089e..4526203253c6c443afd5c84214b00f3f0a0660ca 100644 (file)
@@ -176,7 +176,7 @@ int namedev_init_rules(void)
                        ++temp;
 
                /* empty line? */
-               if (*temp == 0x00)
+               if ((*temp == 0x00) || (*temp == 0x0a))
                        continue;
 
                /* see if this is a comment */
@@ -378,7 +378,7 @@ int namedev_init_permissions(void)
                        ++temp;
 
                /* empty line? */
-               if (*temp == 0x00)
+               if ((*temp == 0x00) || (*temp == 0x0a))
                        continue;
 
                /* see if this is a comment */