diff --git a/net/wide-dhcp/patches/patch-an b/net/wide-dhcp/patches/patch-an index 94e979fc0d1..86d13155a46 100644 --- a/net/wide-dhcp/patches/patch-an +++ b/net/wide-dhcp/patches/patch-an @@ -1,5 +1,5 @@ *** server/dhcps.c.orig Tue Aug 19 14:14:39 1997 ---- server/dhcps.c Wed Apr 29 15:39:18 1998 +--- server/dhcps.c Fri Jun 5 09:27:41 1998 *************** *** 126,132 **** @@ -39,6 +39,23 @@ init_db(); /* initialize databases */ *************** +*** 1832,1838 **** + snd.dhcp->options[off_options] = END; + } else if (off_extopt > 0 && off_extopt < maxoptlen - DFLTOPTLEN && + sbufvec[1].iov_base != NULL) { +! sbufvec[1].iov_base[off_extopt++] = END; + } + + if (off_extopt < sbufvec[1].iov_len) { +--- 1832,1838 ---- + snd.dhcp->options[off_options] = END; + } else if (off_extopt > 0 && off_extopt < maxoptlen - DFLTOPTLEN && + sbufvec[1].iov_base != NULL) { +! *((char *)sbufvec[1].iov_base + off_extopt++) = END; + } + + if (off_extopt < sbufvec[1].iov_len) { +*************** *** 2290,2296 **** --- 2290,2300 ---- char *inserted; @@ -53,6 +70,23 @@ int symbol = 0; int retval = 0; *************** +*** 2851,2857 **** + len -= done; + off_options += done; /* invalid offset, So, to access + here will cause fatal error */ +! bcopy(&opt[done], &sbufvec[1].iov_base[off_extopt], len); + off_extopt += len; + return(0); + } +--- 2855,2861 ---- + len -= done; + off_options += done; /* invalid offset, So, to access + here will cause fatal error */ +! bcopy(&opt[done], (char *)sbufvec[1].iov_base + off_extopt, len); + off_extopt += len; + return(0); + } +*************** *** 2927,2933 **** return(GOOD); }