fix svace issue 51/132851/1 accepted/tizen/unified/20170608.184633 submit/tizen/20170608.070633
authorJongkyu Koo <jk.koo@samsung.com>
Thu, 8 Jun 2017 04:24:00 +0000 (13:24 +0900)
committerJongkyu Koo <jk.koo@samsung.com>
Thu, 8 Jun 2017 04:24:00 +0000 (13:24 +0900)
Change-Id: I749f409da0bc04d8533772812d223a0d17809136
Signed-off-by: Jongkyu Koo <jk.koo@samsung.com>
server/ctsvc_schema_recovery.c

index 60b6cc6..17aa3d8 100644 (file)
@@ -48,8 +48,8 @@ static inline int __ctsvc_server_check_db_file(void)
 static inline int __ctsvc_server_remake_db_file()
 {
        int ret;
-       char *errmsg;
-       sqlite3 *db;
+       char *errmsg = NULL;
+       sqlite3 *db = NULL;
 
        ret = ctsvc_server_db_open(&db);
        RETVM_IF(CONTACTS_ERROR_NONE != ret, ret, "ctsvc_server_db_open() Fail(%d)", ret);
@@ -70,7 +70,7 @@ static inline int __ctsvc_server_remake_db_file()
 static int __ctsvc_server_check_table()
 {
        int ret;
-       sqlite3 *db;
+       sqlite3 *db = NULL;
        char query[CTS_SQL_MAX_LEN] = {0};
        cts_stmt stmt = NULL;