qcacmn: Fix maybe-uninitialized compilation failure
'dest_desc' may be used uninitialized in function
ce_recv_buf_enqueue_srng/hif_record_ce_srng_desc_event, when
Werror=maybe-uninitialized enabled.
Change-Id: I13281d74bcfff5eb7474af729fd70d90c024ee75
CRs-Fixed: 2519213
diff --git a/hif/src/ce/ce_service_srng.c b/hif/src/ce/ce_service_srng.c
index 18593b1..4864678 100644
--- a/hif/src/ce/ce_service_srng.c
+++ b/hif/src/ce/ce_service_srng.c
@@ -340,8 +340,10 @@
write_index);
status = QDF_STATUS_SUCCESS;
}
- } else
+ } else {
+ dest_desc = NULL;
status = QDF_STATUS_E_FAILURE;
+ }
dest_ring->write_index = write_index;
hal_srng_access_end(scn->hal_soc, dest_ring->srng_ctx);