1
0
mirror of https://github.com/openbsd/src.git synced 2026-06-18 07:13:36 +02:00

do not set IFF_RUNNING if qwx_init() fails to start the MAC

This commit is contained in:
stsp
2026-05-31 13:51:58 +00:00
parent c2ad70cf28
commit 123f50350e
+2 -2
View File
@@ -1,4 +1,4 @@
/* $OpenBSD: qwx.c,v 1.121 2026/05/31 13:21:55 stsp Exp $ */
/* $OpenBSD: qwx.c,v 1.122 2026/05/31 13:51:58 stsp Exp $ */
/*
* Copyright 2023 Stefan Sperling <stsp@openbsd.org>
@@ -317,12 +317,12 @@ qwx_init(struct ifnet *ifp)
refcnt_init(&sc->task_refs);
ifq_clr_oactive(&ifp->if_snd);
ifp->if_flags |= IFF_RUNNING;
error = qwx_mac_start(sc);
if (error)
return error;
ifp->if_flags |= IFF_RUNNING;
ieee80211_begin_scan(ifp);
}