From d4fe5f748ff21a6304d40648986d7d278d28151a Mon Sep 17 00:00:00 2001 From: Himanshu Agarwal Date: Mon, 20 Feb 2017 11:28:44 +0530 Subject: [PATCH] qcacld-3.0: Avoid NULL pointer dereferencing of mpdu_buf Avoid NULL pointer dereferencing of mpdu_buf by putting NULL check before using it in htt_rx_restitch_mpdu_from_msdus func. Change-Id: I726891d4fc1f6928cbda911932dbbcd2ec681b63 CRs-Fixed: 2008901 --- core/dp/htt/htt_rx.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/core/dp/htt/htt_rx.c b/core/dp/htt/htt_rx.c index 7ae3b1fde40c..2000f14a9391 100644 --- a/core/dp/htt/htt_rx.c +++ b/core/dp/htt/htt_rx.c @@ -2223,6 +2223,9 @@ htt_rx_restitch_mpdu_from_msdus(htt_pdev_handle pdev, else mpdu_buf = qdf_nbuf_clone(head_msdu); + if (!mpdu_buf) + goto mpdu_stitch_fail; + prev_buf = mpdu_buf; frag_list_sum_len = 0;