summaryrefslogtreecommitdiff
path: root/sys/dev/usb/if_zyd.c
diff options
context:
space:
mode:
Diffstat (limited to 'sys/dev/usb/if_zyd.c')
-rw-r--r--sys/dev/usb/if_zyd.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/sys/dev/usb/if_zyd.c b/sys/dev/usb/if_zyd.c
index 7f736cbda79..6fb0b3c6af7 100644
--- a/sys/dev/usb/if_zyd.c
+++ b/sys/dev/usb/if_zyd.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_zyd.c,v 1.18 2006/07/02 02:59:21 jsg Exp $ */
+/* $OpenBSD: if_zyd.c,v 1.19 2006/07/02 06:52:36 jsg Exp $ */
/*
* Copyright (c) 2006 by Florian Stoehr <ich@florian-stoehr.de>
@@ -3583,10 +3583,8 @@ zyd_start(struct ifnet *ifp)
bpf_mtap(ifp->if_bpf, m0, BPF_DIRECTION_OUT);
#endif
- m0 = ieee80211_encap(ifp, m0, &ni);
-
- if (m0 == NULL) {
- ieee80211_release_node(ic, ni);
+ if ((m0 = ieee80211_encap(ifp, m0, &ni)) == NULL) {
+ ifp->if_oerrors++;
continue;
}