commit | 3e44eb36c5b1ceea4d231ca3d8d4e99b2850b3ca | [log] [tgz] |
---|---|---|
author | hong.liu <hong.liu@mobiletek.cn> | Thu Sep 19 06:26:36 2024 +0000 |
committer | Gerrit Code Review <gerrit@aab99bac79d8> | Thu Sep 19 06:26:36 2024 +0000 |
tree | 88267a65105bcfedc90d561e56e096498ac1264a | |
parent | c65b9b14262479e18b954fa962e1a0e4a4daf5df [diff] | |
parent | f91e66b22038d58098817370bfdda105ca06edd7 [diff] |
Merge "[Bugfix][T106][bug-view-222]Fix the memory leak issue of the SIM module and GNSS module"
diff --git a/cap/zx297520v3/src/lynq/lib/liblynq-qser-gnss/src/mbtk_gnss.cpp b/cap/zx297520v3/src/lynq/lib/liblynq-qser-gnss/src/mbtk_gnss.cpp index 59db5a0..04ab964 100755 --- a/cap/zx297520v3/src/lynq/lib/liblynq-qser-gnss/src/mbtk_gnss.cpp +++ b/cap/zx297520v3/src/lynq/lib/liblynq-qser-gnss/src/mbtk_gnss.cpp
@@ -1665,6 +1665,8 @@ hd_agnss_fd = open(AGNSS_TLE_FILE, O_RDWR); if (hd_agnss_fd <= 0) { + free(databuf); + databuf = NULL; printf("%s open file FAIL. errno:%d\n", __FUNCTION__, errno); return -1; }
diff --git a/cap/zx297520v3/src/lynq/lib/liblynq-sim/lynq_sim.cpp b/cap/zx297520v3/src/lynq/lib/liblynq-sim/lynq_sim.cpp index 1bfcb38..e5905c2 100755 --- a/cap/zx297520v3/src/lynq/lib/liblynq-sim/lynq_sim.cpp +++ b/cap/zx297520v3/src/lynq/lib/liblynq-sim/lynq_sim.cpp
@@ -447,6 +447,7 @@ if(res != 0) { + free(p_info); RLOGD("function %s execute error", __FUNCTION__); return res; }