Re: [PATCH] biosdisk, getroot for Cygwin

2008-05-16 Thread Christian Franke
Done, new patch below. If there are no further comments, I will commit it in a few days. Committed. Christian ___ Grub-devel mailing list Grub-devel@gnu.org http://lists.gnu.org/mailman/listinfo/grub-devel

Re: [PATCH] biosdisk, getroot for Cygwin

2008-05-13 Thread Christian Franke
Robert Millan wrote: On Fri, May 09, 2008 at 07:32:42PM +0200, Christian Franke wrote: + char devpath[sizeof ("/dev/sda15") + 13]; Where does this 13 come from? Would be nice to make it explicit (e.g. sizeof(something) or so). 13 "paranoia" bytes added to the required

Re: [PATCH] biosdisk, getroot for Cygwin

2008-05-12 Thread Robert Millan
On Fri, May 09, 2008 at 07:32:42PM +0200, Christian Franke wrote: > >>+ char devpath[sizeof ("/dev/sda15") + 13]; > >> > > > >Where does this 13 come from? Would be nice to make it explicit (e.g. > >sizeof(something) or so). > > 13 "paranoia" bytes added to the required size :-) A comment s

Re: [PATCH] biosdisk, getroot for Cygwin

2008-05-11 Thread Christian Franke
Christian Franke wrote: Robert Millan wrote: On Wed, May 07, 2008 at 10:42:23PM +0200, Christian Franke wrote: +#ifndef __CYGWIN__ #ifdef __linux__ /* We first try to find the device in the /dev/mapper directory. If we don't do this, we get useless device names like /dev/dm-0 for @@

Re: [PATCH] biosdisk, getroot for Cygwin

2008-05-09 Thread Christian Franke
Robert Millan wrote: On Wed, May 07, 2008 at 10:42:23PM +0200, Christian Franke wrote: + + /* Check signature. */ + if (!(buf[0x1fe] == 0x55 && buf[0x1ff] == 0xaa)) +return ~0; + + /* Serial number offset depends on boot sector type. */ + if (mbr) +n = 0x1b8; + else if (memcmp

Re: [PATCH] biosdisk, getroot for Cygwin

2008-05-09 Thread Robert Millan
On Wed, May 07, 2008 at 10:42:23PM +0200, Christian Franke wrote: > + > + /* Check signature. */ > + if (!(buf[0x1fe] == 0x55 && buf[0x1ff] == 0xaa)) > +return ~0; > + > + /* Serial number offset depends on boot sector type. */ > + if (mbr) > +n = 0x1b8; > + else if (memcmp (buf + 0x

Re: [PATCH] biosdisk, getroot for Cygwin

2008-05-07 Thread Christian Franke
Updated version of the patch. It adds the functionality necessary for grub-probe on Cygwin. It also fixes 2 bugs in strip_extra_slashes() and __GNU__ get_os_disk() Christian 2008-05-07 Christian Franke <[EMAIL PROTECTED]> * util/biosdisk.c: [__CYGWIN__] Add includes. (grub_u

[PATCH] biosdisk, getroot for Cygwin

2007-11-23 Thread Christian Franke
This patch adds the functionality necessary for grub-probe on Cygwin. It also fixes 2 bugs in strip_extra_slashes() and __GNU__ get_os_disk(). Christian 2007-11-23 Christian Franke <[EMAIL PROTECTED]> * util/biosdisk.c: [__CYGWIN__] Add includes. (grub_util_biosdisk_open): Us