From 47d5d01a45d64d231fb856a9cdfecf5d567371e6 Mon Sep 17 00:00:00 2001 From: ths Date: Tue, 20 Feb 2007 00:05:08 +0000 Subject: Add -bootp option for slirp, by Anthony Liguori. git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2439 c046a42c-6fe2-441c-8c8c-71466251a162 --- slirp/bootp.c | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'slirp/bootp.c') diff --git a/slirp/bootp.c b/slirp/bootp.c index 62cbcfd8f3..9d243a705a 100644 --- a/slirp/bootp.c +++ b/slirp/bootp.c @@ -38,6 +38,8 @@ typedef struct { BOOTPClient bootp_clients[NB_ADDR]; +const char *bootp_filename; + static const uint8_t rfc1533_cookie[] = { RFC1533_COOKIE }; #ifdef DEBUG @@ -168,6 +170,10 @@ static void bootp_reply(struct bootp_t *bp) goto new_addr; } } + + if (bootp_filename) + snprintf(rbp->bp_file, sizeof(rbp->bp_file), "%s", bootp_filename); + dprintf("offered addr=%08x\n", ntohl(daddr.sin_addr.s_addr)); saddr.sin_addr.s_addr = htonl(ntohl(special_addr.s_addr) | CTL_ALIAS); -- cgit v1.2.3