oops! spot the deliberate mistake!
here's an updated patch that won't crash if the tailing slash is
ommited. :-)
--
J.F.Carter http://www.jfc.org.uk/
Only in grub/docs: grub.info
Only in grub/docs: grub.info-1
Only in grub/docs: grub.info-2
Only in grub/docs: grub.info-3
Only in grub/docs: multiboot.info
diff -ru grub-orig/netboot/main.c grub/netboot/main.c
--- grub-orig/netboot/main.c Wed Jan 2 21:56:40 2002
+++ grub/netboot/main.c Thu May 2 12:56:22 2002
@@ -1064,7 +1064,13 @@
of CONFIG_FILE. This kind of robustness will be a goal
in GRUB 1.0. */
grub_memmove (config_file, p + 2, l);
- config_file[l] = 0;
+ /* JFC: if configfile ends in a slash append IP address */
+ if (l && config_file[l-1]=='/') {
+ etherboot_sprintf(&config_file[l],"%@",
+ arptable[ARP_CLIENT].ipaddr.s_addr);
+ } else {
+ config_file[l] = 0;
+ }
}
p += TAG_LEN (p) + 2;