Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/netbsd-6-0]: src/sys/net Pull up following revision(s) (requested by oza...



details:   https://anonhg.NetBSD.org/src/rev/2beec113863a
branches:  netbsd-6-0
changeset: 774971:2beec113863a
user:      msaitoh <msaitoh%NetBSD.org@localhost>
date:      Thu Aug 07 09:53:29 2014 +0000

description:
Pull up following revision(s) (requested by ozaki-r in ticket #1103):
        sys/net/link_proto.c    revision 1.17
Don't assume if_init is always set. if_init may be NULL, e.g., if_vlan.
PR kern/48997.

diffstat:

 sys/net/link_proto.c |  7 ++++---
 1 files changed, 4 insertions(+), 3 deletions(-)

diffs (28 lines):

diff -r 9abeb031a446 -r 2beec113863a sys/net/link_proto.c
--- a/sys/net/link_proto.c      Thu Aug 07 09:35:22 2014 +0000
+++ b/sys/net/link_proto.c      Thu Aug 07 09:53:29 2014 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: link_proto.c,v 1.7 2011/10/07 16:34:31 dyoung Exp $    */
+/*     $NetBSD: link_proto.c,v 1.7.14.1 2014/08/07 09:53:29 msaitoh Exp $      */
 
 /*-
  * Copyright (c) 1982, 1986, 1993
@@ -32,7 +32,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: link_proto.c,v 1.7 2011/10/07 16:34:31 dyoung Exp $");
+__KERNEL_RCSID(0, "$NetBSD: link_proto.c,v 1.7.14.1 2014/08/07 09:53:29 msaitoh Exp $");
 
 #include <sys/param.h>
 #include <sys/socket.h>
@@ -197,7 +197,8 @@
                splx(s);
                if (error != ENETRESET)
                        return error;
-               else if ((ifp->if_flags & IFF_RUNNING) != 0)
+               else if ((ifp->if_flags & IFF_RUNNING) != 0 &&
+                        ifp->if_init != NULL)
                        return (*ifp->if_init)(ifp);
                else
                        return 0;



Home | Main Index | Thread Index | Old Index