mirror of
https://github.com/Divested-Mobile/DivestOS-Build.git
synced 2024-10-01 01:35:54 -04:00
34 lines
1.2 KiB
Diff
34 lines
1.2 KiB
Diff
From 2720294757d0ad5294283c15dc837852f7b2329a Mon Sep 17 00:00:00 2001
|
|
From: Gaurav Kohli <gkohli@codeaurora.org>
|
|
Date: Thu, 4 Aug 2016 17:40:15 +0530
|
|
Subject: soc: qcom: Initialize message pointer with NULL
|
|
|
|
During service locator call there is a chance in which
|
|
resp message is used or freed while uninitialized.So to
|
|
prevent it initialize the same with NULL.
|
|
|
|
Change-Id: I65f854e184606684ce2ca711f19cf61d26c1ecb5
|
|
Signed-off-by: Gaurav Kohli <gkohli@codeaurora.org>
|
|
---
|
|
drivers/soc/qcom/service-locator.c | 4 ++--
|
|
1 file changed, 2 insertions(+), 2 deletions(-)
|
|
|
|
diff --git a/drivers/soc/qcom/service-locator.c b/drivers/soc/qcom/service-locator.c
|
|
index 76d754d..c204947 100644
|
|
--- a/drivers/soc/qcom/service-locator.c
|
|
+++ b/drivers/soc/qcom/service-locator.c
|
|
@@ -202,8 +202,8 @@ static int servreg_loc_send_msg(struct msg_desc *req_desc,
|
|
static int service_locator_send_msg(struct pd_qmi_client_data *pd)
|
|
{
|
|
struct msg_desc req_desc, resp_desc;
|
|
- struct qmi_servreg_loc_get_domain_list_resp_msg_v01 *resp;
|
|
- struct qmi_servreg_loc_get_domain_list_req_msg_v01 *req;
|
|
+ struct qmi_servreg_loc_get_domain_list_resp_msg_v01 *resp = NULL;
|
|
+ struct qmi_servreg_loc_get_domain_list_req_msg_v01 *req = NULL;
|
|
int rc;
|
|
int db_rev_count = 0, domains_read = 0;
|
|
|
|
--
|
|
cgit v1.1
|
|
|