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

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

Diff for /src/sys/kern/uipc_socket.c between version 1.169 and 1.170

version 1.169, 2008/07/25 22:45:58 version 1.170, 2008/08/04 03:55:47
Line 65 
Line 65 
 #include <sys/cdefs.h>  #include <sys/cdefs.h>
 __KERNEL_RCSID(0, "$NetBSD$");  __KERNEL_RCSID(0, "$NetBSD$");
   
   #include "opt_inet.h"
 #include "opt_sock_counters.h"  #include "opt_sock_counters.h"
 #include "opt_sosend_loan.h"  #include "opt_sosend_loan.h"
 #include "opt_mbuftrace.h"  #include "opt_mbuftrace.h"
Line 624  sofree(struct socket *so)
Line 625  sofree(struct socket *so)
         KASSERT(!cv_has_waiters(&so->so_snd.sb_cv));          KASSERT(!cv_has_waiters(&so->so_snd.sb_cv));
         sorflush(so);          sorflush(so);
         refs = so->so_aborting; /* XXX */          refs = so->so_aborting; /* XXX */
   #ifdef INET
           /* remove acccept filter if one is present. */
           if (so->so_accf != NULL)
                   do_setopt_accept_filter(so, NULL);
   #endif
         sounlock(so);          sounlock(so);
         if (refs == 0)          /* XXX */          if (refs == 0)          /* XXX */
                 soput(so);                  soput(so);
Line 1572  sorflush(struct socket *so)
Line 1578  sorflush(struct socket *so)
 static int  static int
 sosetopt1(struct socket *so, int level, int optname, struct mbuf *m)  sosetopt1(struct socket *so, int level, int optname, struct mbuf *m)
 {  {
   #ifdef INET
           int error, optval, val;
   #else
         int optval, val;          int optval, val;
   #endif
         struct linger   *l;          struct linger   *l;
         struct sockbuf  *sb;          struct sockbuf  *sb;
         struct timeval *tv;          struct timeval *tv;
   
         switch (optname) {          switch (optname) {
   
   #ifdef INET
           case SO_ACCEPTFILTER:
                   error = do_setopt_accept_filter(so, m);
                   if (error)
                           return error;
                   break;
   #endif
   
         case SO_LINGER:          case SO_LINGER:
                 if (m == NULL || m->m_len != sizeof(struct linger))                  if (m == NULL || m->m_len != sizeof(struct linger))
                         return EINVAL;                          return EINVAL;
Line 1726  sogetopt(struct socket *so, int level, i
Line 1744  sogetopt(struct socket *so, int level, i
   
                 switch (optname) {                  switch (optname) {
   
   #ifdef INET
                   case SO_ACCEPTFILTER:
                           error = do_getopt_accept_filter(so, m);
                           break;
   #endif
   
                 case SO_LINGER:                  case SO_LINGER:
                         m->m_len = sizeof(struct linger);                          m->m_len = sizeof(struct linger);
                         mtod(m, struct linger *)->l_onoff =                          mtod(m, struct linger *)->l_onoff =

Legend:
Removed from v.1.169  
changed lines
  Added in v.1.170

CVSweb <webmaster@jp.NetBSD.org>