rssi: use vconf API to set RSSI 27/97427/1
authorJinhyung Choi <jinh0.choi@samsung.com>
Mon, 14 Nov 2016 07:04:11 +0000 (16:04 +0900)
committerJinhyung Choi <jinh0.choi@samsung.com>
Mon, 14 Nov 2016 07:04:11 +0000 (16:04 +0900)
Two different ways are implemented to get and to set RSSI.
vconf internal API is used To get RSSI value and systemcall is used to set it.
systemcall is slow and discouraged for security reason.
So, setting RSSI is changed to use vconf internal API.

Change-Id: I1f28d1dfdd21b87ad952684d962b8ff97c4a50e6
Signed-off-by: Jinhyung Choi <jinh0.choi@samsung.com>
src/mobile.cpp

index cc789e391053cf4e1db1e51be3f4b2bba6740243..36aa80404a6ec152b10578ebe8b5b26b4e09da18 100644 (file)
@@ -359,8 +359,7 @@ int parse_rssi_data(int len, char *buffer)
 
     x = atoi(tmpbuf);
 
-    snprintf(command, sizeof(command), "vconftool set -t int memory/telephony/rssi %d -i -f", x);
-    systemcall(command);
+    vconf_set_int(VCONF_RSSI, x);
 
     return 0;
 }