[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Bug-xorriso] bootspec grub2_mbr broken
From: |
Daniel Martin |
Subject: |
[Bug-xorriso] bootspec grub2_mbr broken |
Date: |
Fri, 4 Apr 2014 14:36:34 +0200 |
Hi,
I just wanted to test the xorriso option grub2_mbr and got:
xorriso : FAILURE : Unrecognized keyword with -boot_image grub grub2_mbr=on
xorriso : HINT : Allowed with grub2_mbr= are: off , on
What?
The problem seems to exists since its introduction as the code hasn't changed:
http://libburnia-project.org/browser/libisoburn/trunk/xorriso/opts_a_c.c#L1129
Here the string comparisions are wrong:
strcmp(treatpt + 9, "off")
and
strcmp(treatpt + 9, "on").
+9 is one character to short as it misses the equal sign and the
strcmps compare on/off with =on/=off.
(Just quickly) comparing it with other options the initial check:
strncmp(treatpt, "grub2_mbr=", 9)
should've been
strncmp(treatpt, "grub2_mbr=", 10)
and the following "+9"s might be copy errors.
I hope that I have the time to send a patch this evening.
But, when seeing this error no one should have been able to use this
option before. Is it supposed to work? ;)
Cheers,
Daniel Martin
- [Bug-xorriso] bootspec grub2_mbr broken,
Daniel Martin <=