]> git.ipfire.org Git - thirdparty/grub.git/commitdiff
syslinux_parse: Always output comments even if no entries are found.
authorVladimir Serbinenko <phcoder@gmail.com>
Mon, 16 Feb 2015 09:54:20 +0000 (10:54 +0100)
committerVladimir Serbinenko <phcoder@gmail.com>
Mon, 16 Feb 2015 09:54:20 +0000 (10:54 +0100)
grub-core/lib/syslinux_parse.c

index 2c874b1fa5c364d774317864d75cf7e76701ff71..46eff1e5df9a85311f575830a9896e45835ee44a 100644 (file)
@@ -1430,6 +1430,13 @@ config_file (struct output_buffer *outbuf,
       print_string ("\n");
     }
 
+  if (menu.comments)
+    {
+      err = print (outbuf, menu.comments, grub_strlen (menu.comments));
+      if (err)
+       return err;
+    }
+
   if (menu.timeout == 0 && menu.entries && menu.def)
     {
       err = print_entry (outbuf, &menu, menu.def);
@@ -1446,12 +1453,6 @@ config_file (struct output_buffer *outbuf,
       if (err)
        return err;
       print_string ("\n");
-      if (menu.comments)
-       {
-         err = print (outbuf, menu.comments, grub_strlen (menu.comments));
-         if (err)
-           return err;
-       }
 
       if (menu.def)
        {