pkgsrc-Changes-HG archive

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

[pkgsrc/trunk]: pkgsrc/net/netbsd-tap/files Report revision 1.4 from main tree.



details:   https://anonhg.NetBSD.org/pkgsrc/rev/b654b68fe250
branches:  trunk
changeset: 488132:b654b68fe250
user:      cube <cube%pkgsrc.org@localhost>
date:      Tue Jan 25 10:26:52 2005 +0000

description:
Report revision 1.4 from main tree.

Do not cast simple_lock() to (void).  It may be a do { } while() macro,
and then compilation fails.  Found by Håvard Eidnes.

diffstat:

 net/netbsd-tap/files/if_tap.c |  10 +++++-----
 1 files changed, 5 insertions(+), 5 deletions(-)

diffs (45 lines):

diff -r e8f67a10ee4e -r b654b68fe250 net/netbsd-tap/files/if_tap.c
--- a/net/netbsd-tap/files/if_tap.c     Tue Jan 25 10:10:01 2005 +0000
+++ b/net/netbsd-tap/files/if_tap.c     Tue Jan 25 10:26:52 2005 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: if_tap.c,v 1.1.1.1 2005/01/20 18:02:40 cube Exp $      */
+/*     $NetBSD: if_tap.c,v 1.2 2005/01/25 10:26:52 cube Exp $  */
 
 /*
  *  Copyright (c) 2003, 2004 The NetBSD Foundation.
@@ -43,7 +43,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: if_tap.c,v 1.1.1.1 2005/01/20 18:02:40 cube Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_tap.c,v 1.2 2005/01/25 10:26:52 cube Exp $");
 
 #if defined(_KERNEL_OPT)
 #include "bpfilter.h"
@@ -1092,7 +1092,7 @@
                if (m != NULL)
                        revents |= events & (POLLIN|POLLRDNORM);
                else {
-                       (void)simple_lock(&sc->sc_kqlock);
+                       simple_lock(&sc->sc_kqlock);
                        selrecord(p, &sc->sc_rsel);
                        simple_unlock(&sc->sc_kqlock);
                }
@@ -1140,7 +1140,7 @@
        }
 
        kn->kn_hook = sc;
-       (void)simple_lock(&sc->sc_kqlock);
+       simple_lock(&sc->sc_kqlock);
        SLIST_INSERT_HEAD(&sc->sc_rsel.sel_klist, kn, kn_selnext);
        simple_unlock(&sc->sc_kqlock);
        return (0);
@@ -1151,7 +1151,7 @@
 {
        struct tap_softc *sc = (struct tap_softc *)kn->kn_hook;
 
-       (void)simple_lock(&sc->sc_kqlock);
+       simple_lock(&sc->sc_kqlock);
        SLIST_REMOVE(&sc->sc_rsel.sel_klist, kn, knote, kn_selnext);
        simple_unlock(&sc->sc_kqlock);
 }



Home | Main Index | Thread Index | Old Index