[klibc] PATCH: command line argument for ipconfig to require a dhcp option

Άλκης Άλκης
Thu Oct 9 10:39:48 PDT 2008


Oops, in my previous mail I forgot to give an explanation for the
following lines, which are actualy a bug fix and not really part of the
patch:


Στις 09-10-2008, ημέρα Πεμ, και ώρα 19:25 +0300, ο/η Άλκης Γεωργόπουλος
έγραψε:
> case 67:        /* bootfile name, when option overload is set */
>       if (len > sizeof(dev->filename) - 1)
>               len = sizeof(dev->filename) - 1;
>       memcpy(&dev->filename, ext, len);
>       dev->filename[len] = '\0';
>       break;


Bootfile name may be offered either in the bootp header (file field),
or, when "option overload" (=option 52) is set, in the variable dhcp
options field as option 67.

So previously ipconfig incorrectly didn't accept option 67 as a bootfile
name.

This is still true (=incorrect) for the sname field in the bootp header,
which may also be offered as option 66, but sname is not currently used
anywhere in the code, so I didn't insert similar code for "case 66:".


Kind regards,
Alkis Georgopoulos



More information about the klibc mailing list