bug-grub
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[bugs #9673] segfault at startup due to too many disks


From: Egmont Koblinger
Subject: [bugs #9673] segfault at startup due to too many disks
Date: Fri, 16 Jul 2004 17:35:40 -0400
User-agent: Mozilla/5.0 (X11; Linux i686; U) Opera 7.52 [en]

This mail is an automated notification from the bugs tracker
 of the project: GNU GRUB.




/**************************************************************************/
[bugs #9673] Full Item Snapshot:

URL: <http://savannah.gnu.org/bugs/?func=detailitem&item_id=9673>
Project: GNU GRUB
Submitted by: Egmont Koblinger
On: Fri 07/16/04 at 21:32

Category:  Disk &amp; Partition
Severity:  Major
Priority:  5 - Normal
Item Group:  Software Error
Resolution:  None
Assigned to:  None
Originator Name:  egmont
Originator Email:  address@hidden
Status:  Open
Release:  0.95
Reproducibility:  Every Time
Planned Release:  


Summary:  segfault at startup due to too many disks

Original Submission:  
Suddenly I noticed that an interactive startup of the grub
os shell exitst with a segmentation fault. It took about
two hours for me to locate the issue. The segfault only
occurs if I don't give an existing device.map to grub.

lib/device.c starts to put entries of hard disks to a
buffer of size 256, starting at offset 128 (0x80), counting
the number of hard disks in num_hd. And it doesn't check
for overrun.

I have two disks, /dev/discs/disc[01] point to them, and
I have 256 more files under /dev/discs (disc2 ... disc257)
all pointing to "../" . So no wonder grub segfaults while
filling up (well, actually not when filling up, but later
when accessing) this array.

Yes, I know, it is a bug in my kernel or devfsd or whatever,
not in GRUB.

However, I guess a limit check in GRUB cannot hurt anyone.
Patch attached. Don't ask my why the limit for the number
of hard disks is 0x40. Could be 0x7f or whatsoever. Maybe
an expert knows the maximum number of disks any BIOS may
handle.






File Attachments
-------------------

-------------------------------------------------------
Date: Fri 07/16/04 at 21:32  Name: limit-number-of-disks.patch  Size: 538B   
By: egmont

http://savannah.gnu.org/bugs/download.php?item_id=9673&amp;item_file_id=1500






For detailed info, follow this link:
<http://savannah.gnu.org/bugs/?func=detailitem&item_id=9673>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/







reply via email to

[Prev in Thread] Current Thread [Next in Thread]