grub crashes setting up a EXT2_GOOD_OLD_REV filesystem

Bug #331002 reported by Colin McQuillan
Affects Status Importance Assigned to Milestone
grub (Gentoo Linux)
Fix Released
grub (Ubuntu)

Bug Description

Binary package hint: grub

grub 0.97-29ubuntu21, on Ubuntu 8.04.2

To reproduce this bug, create an empty filesystem with genext2fs and install grub onto it. In this test there isn't any grub config so the grub utility should just say "file not found", but instead it crashes.

$ genext2fs -b 2048 test.img
$ grub --batch
Probing devices to guess BIOS drives. This may take a long time.

       [ Minimal BASH-like line editing is supported. For
         the first word, TAB lists possible command
         completions. Anywhere else TAB lists the possible
         completions of a device/filename. ]
grub> device (fd0) test.img
device (fd0) test.img
grub> root (fd0)
root (fd0)
grub> setup (fd0)
setup (fd0)
Floating point exception

This has been corrected in

On line debian/patches/ext3_256byte_inode.diff, instead of

+#define EXT2_INODE_SIZE(s) (s->s_inode_size)

It should be:

+#define EXT2_GOOD_OLD_REV 0 /* The good old (original) format */
+#define EXT2_DYNAMIC_REV 1 /* V2 format w/ dynamic inode sizes */
+#define EXT2_INODE_SIZE(s) (((s)->s_rev_level == EXT2_GOOD_OLD_REV) ? \
+ (s)->s_inode_size)

I'm not sure if the patch can just be edited. I presume the patch would then have incorrect line numbers.

Revision history for this message
Colin McQuillan (m-niloc) wrote :

I've managed to redo the patch. This diff supercedes the existing debian/rules/ext3_256byte_inode.diff.

Changed in grub (Gentoo Linux):
status: Unknown → Fix Released
Changed in grub (Gentoo Linux):
importance: Unknown → Medium
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.