diff options
author | Jonathan Gray <jsg@cvs.openbsd.org> | 2006-08-05 12:59:54 +0000 |
---|---|---|
committer | Jonathan Gray <jsg@cvs.openbsd.org> | 2006-08-05 12:59:54 +0000 |
commit | 40cd3a9d4cb5ff82850027f4b9abc4be125e1da6 (patch) | |
tree | aa61874c095cb968a9e78670630c68a066f5de28 | |
parent | 1efd600e3f59ae2060f8b972b9f517be401a8a03 (diff) |
If ieee80211_encap() returns NULL the node is already free,
do not try to free it again.
-rw-r--r-- | sys/dev/ic/acx.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/sys/dev/ic/acx.c b/sys/dev/ic/acx.c index 6eb14d7e79d..154a7a2532f 100644 --- a/sys/dev/ic/acx.c +++ b/sys/dev/ic/acx.c @@ -1,4 +1,4 @@ -/* $OpenBSD: acx.c,v 1.20 2006/08/05 11:34:11 jsg Exp $ */ +/* $OpenBSD: acx.c,v 1.21 2006/08/05 12:59:53 jsg Exp $ */ /* * Copyright (c) 2006 Jonathan Gray <jsg@openbsd.org> @@ -927,9 +927,7 @@ acx_start(struct ifnet *ifp) /* TODO power save */ - m = ieee80211_encap(ifp, m, &ni); - if (m == NULL) { - ieee80211_release_node(ic, ni); + if ((m = ieee80211_encap(ifp, m, &ni)) == NULL) { ifp->if_oerrors++; continue; } |