Commit ae857a15 authored by rahul gurram's avatar rahul gurram Committed by Fabio Baltieri
Browse files

driver: wifi: siwx917: Fix the return case gracefully



Freeing the buf when sl_wifi_send_raw_data_frame() api returns
the error instead of success

Signed-off-by: default avatarrahul gurram <rahul.gurram@silabs.com>
parent 1a128895
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -306,6 +306,7 @@ static int siwx91x_send(const struct device *dev, struct net_pkt *pkt)

	ret = sl_wifi_send_raw_data_frame(SL_WIFI_CLIENT_INTERFACE, buf->data, pkt_len);
	if (ret) {
		net_buf_unref(buf);
		return -EIO;
	}