[BACK]Return to raw_ip.c CVS log [TXT][DIR] Up to [cvs.NetBSD.org] / src / sys / netinet

Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.

Diff for /src/sys/netinet/raw_ip.c between version 1.41.6.1 and 1.42

version 1.41.6.1, 1998/12/11 04:53:09 version 1.42, 1999/01/30 21:43:16
Line 112  rip_input(m, va_alist)
Line 112  rip_input(m, va_alist)
         ripsrc.sin_port = 0;          ripsrc.sin_port = 0;
         bzero((caddr_t)ripsrc.sin_zero, sizeof(ripsrc.sin_zero));          bzero((caddr_t)ripsrc.sin_zero, sizeof(ripsrc.sin_zero));
   
           /*
            * XXX Compatibility: programs using raw IP expect ip_len
            * XXX to have the header length subtracted.
            */
           ip->ip_len -= ip->ip_hl << 2;
   
         for (inp = rawcbtable.inpt_queue.cqh_first;          for (inp = rawcbtable.inpt_queue.cqh_first;
             inp != (struct inpcb *)&rawcbtable.inpt_queue;              inp != (struct inpcb *)&rawcbtable.inpt_queue;
             inp = inp->inp_queue.cqe_next) {              inp = inp->inp_queue.cqe_next) {
Line 308  rip_bind(inp, nam)
Line 314  rip_bind(inp, nam)
         struct mbuf *nam;          struct mbuf *nam;
 {  {
         struct sockaddr_in *addr = mtod(nam, struct sockaddr_in *);          struct sockaddr_in *addr = mtod(nam, struct sockaddr_in *);
         struct ifaddr *ifa = NULL;  
   
         if (nam->m_len != sizeof(*addr))          if (nam->m_len != sizeof(*addr))
                 return (EINVAL);                  return (EINVAL);
Line 318  rip_bind(inp, nam)
Line 323  rip_bind(inp, nam)
             addr->sin_family != AF_IMPLINK)              addr->sin_family != AF_IMPLINK)
                 return (EAFNOSUPPORT);                  return (EAFNOSUPPORT);
         if (!in_nullhost(addr->sin_addr) &&          if (!in_nullhost(addr->sin_addr) &&
             (ifa = ifa_ifwithaddr(sintosa(addr))) == 0)              ifa_ifwithaddr(sintosa(addr)) == 0)
                 return (EADDRNOTAVAIL);                  return (EADDRNOTAVAIL);
         inp->inp_laddr = addr->sin_addr;          inp->inp_laddr = addr->sin_addr;
         if (ifa != NULL)  
                 ifa_delref(ifa);  
         return (0);          return (0);
 }  }
   

Legend:
Removed from v.1.41.6.1  
changed lines
  Added in v.1.42

CVSweb <webmaster@jp.NetBSD.org>