diff -rcN dhcp-1.4.0p5/server/common_subr.h dhcp-1.4.0p6/server/common_subr.h
*** dhcp-1.4.0p5/server/common_subr.h	Wed Mar  3 18:56:49 1999
--- dhcp-1.4.0p6/server/common_subr.h	Wed Mar  3 18:58:01 1999
***************
*** 37,43 ****
   * WIDE project has the rights to redistribute these changes.
   */
  
! #define WIDEDHCP_VERS    "1.4.0p5"
  
  struct ps_udph {              /* pseudo udp header for checksum */
    struct in_addr srcip,
--- 37,43 ----
   * WIDE project has the rights to redistribute these changes.
   */
  
! #define WIDEDHCP_VERS    "1.4.0p6"
  
  struct ps_udph {              /* pseudo udp header for checksum */
    struct in_addr srcip,
diff -rcN dhcp-1.4.0p5/server/dhcps.c dhcp-1.4.0p6/server/dhcps.c
*** dhcp-1.4.0p5/server/dhcps.c	Wed Mar  3 18:56:49 1999
--- dhcp-1.4.0p6/server/dhcps.c	Wed Mar  3 18:58:01 1999
***************
*** 142,148 ****
  int  nmacaddr;
  #endif
  
! void
  main(argc, argv)
    int argc;
    char **argv;
--- 142,148 ----
  int  nmacaddr;
  #endif
  
! int
  main(argc, argv)
    int argc;
    char **argv;
***************
*** 441,446 ****
--- 441,448 ----
      }
    }
  #endif /* not sun */
+ 
+   return(0);
  }
  
  
***************
*** 590,596 ****
      syslog(LOG_ERR, "calloc error send buffer in alloc_buf()");
      exit(1);
    }
!   sbufvec[0].iov_base = &sbufp[QWOFF];
    snd.ether = (struct ether_header *) &sbufp[QWOFF];
    snd.ip = (struct ip *) &sbufp[QWOFF + ETHERHL];
    snd.udp = (struct udphdr *) &sbufp[QWOFF + ETHERHL + IPHL];
--- 592,598 ----
      syslog(LOG_ERR, "calloc error send buffer in alloc_buf()");
      exit(1);
    }
!   sbufvec[0].iov_base = (void *)&sbufp[QWOFF];
    snd.ether = (struct ether_header *) &sbufp[QWOFF];
    snd.ip = (struct ip *) &sbufp[QWOFF + ETHERHL];
    snd.udp = (struct udphdr *) &sbufp[QWOFF + ETHERHL + IPHL];
***************
*** 1927,1933 ****
      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) {
--- 1929,1935 ----
      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) {
***************
*** 1951,1957 ****
        bcopy(&rcv.dhcp->giaddr, &dst.sin_addr, sizeof(u_Long));
      }
  
!     bufvec[0].iov_base = (char *) snd.dhcp;
      buflen = bufvec[0].iov_len = DFLTDHCPLEN;
      bufvec[1].iov_base = sbufvec[1].iov_base;
      if (bufvec[1].iov_base == NULL) {
--- 1953,1959 ----
        bcopy(&rcv.dhcp->giaddr, &dst.sin_addr, sizeof(u_Long));
      }
  
!     bufvec[0].iov_base = (void *) snd.dhcp;
      buflen = bufvec[0].iov_len = DFLTDHCPLEN;
      bufvec[1].iov_base = sbufvec[1].iov_base;
      if (bufvec[1].iov_base == NULL) {
***************
*** 2384,2390 ****
    char *inserted;
    char flag;
  {
!   u_Long *addr = 0;
    char option[6];
    int symbol = 0;
    int retval = 0;
--- 2386,2392 ----
    char *inserted;
    char flag;
  {
!   struct in_addr *addr = NULL;
    char option[6];
    int symbol = 0;
    int retval = 0;
***************
*** 2393,2408 ****
  
    switch(tagnum) {
    case SUBNET_MASK:
!     symbol = S_SUBNET_MASK, addr = &res->subnet_mask->s_addr;
      break;
    case SWAP_SERVER:
!     symbol = S_SWAP_SERVER, addr = &res->swap_server->s_addr;
      break;
    case BRDCAST_ADDR:
!     symbol = S_BRDCAST_ADDR, addr = &res->brdcast_addr->s_addr;
      break;
    case ROUTER_SOLICIT:
!     symbol = S_ROUTER_SOLICIT, addr = &res->router_solicit->s_addr;
      break;
    default:
      return(-1);
--- 2395,2410 ----
  
    switch(tagnum) {
    case SUBNET_MASK:
!     symbol = S_SUBNET_MASK, addr = res->subnet_mask;
      break;
    case SWAP_SERVER:
!     symbol = S_SWAP_SERVER, addr = res->swap_server;
      break;
    case BRDCAST_ADDR:
!     symbol = S_BRDCAST_ADDR, addr = res->brdcast_addr;
      break;
    case ROUTER_SOLICIT:
!     symbol = S_ROUTER_SOLICIT, addr = res->router_solicit;
      break;
    default:
      return(-1);
***************
*** 2945,2951 ****
        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);
      }
--- 2947,2953 ----
        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);
      }
diff -rcN dhcp-1.4.0p5/server/getmac.c dhcp-1.4.0p6/server/getmac.c
*** dhcp-1.4.0p5/server/getmac.c	Wed Mar  3 18:56:49 1999
--- dhcp-1.4.0p6/server/getmac.c	Wed Mar  3 18:58:01 1999
***************
*** 138,144 ****
        continue;
  
      /* Only look at the specified interface */
!     if ( strlen(ifname) != sdl->sdl_nlen)
        continue; /* not same len */
      if (strncmp(ifname, sdl->sdl_data, sdl->sdl_nlen) != 0)
        continue; /* not same name */
--- 138,144 ----
        continue;
  
      /* Only look at the specified interface */
!     if (strlen(ifname) != sdl->sdl_nlen)
        continue; /* not same len */
      if (strncmp(ifname, sdl->sdl_data, sdl->sdl_nlen) != 0)
        continue; /* not same name */
