Set default support-mode to 0 58/202258/2
authorJunghyun Yeon <jungh.yeon@samsung.com>
Tue, 26 Mar 2019 10:19:47 +0000 (19:19 +0900)
committerJunghyun Yeon <jungh.yeon@samsung.com>
Wed, 27 Mar 2019 08:20:58 +0000 (17:20 +0900)
Add default value for support-mode for wgt packages.

Change-Id: I534f9dd17a520901e0f0631c42dddb94af4ca465
Signed-off-by: Junghyun Yeon <jungh.yeon@samsung.com>
parser/src/pkgmgr_parser_db.c

index 185aecb..bf7e35d 100644 (file)
@@ -2017,7 +2017,8 @@ static int __insert_application_info(sqlite3 *db, manifest_x *mfx)
                                __get_bool(app->process_pool, false));
                __BIND_TEXT(db, stmt, idx++, app->launch_mode);
                __BIND_TEXT(db, stmt, idx++, __get_bool(app->ui_gadget, false));
-               __BIND_TEXT(db, stmt, idx++, app->support_mode);
+               __BIND_TEXT(db, stmt, idx++,
+                               app->support_mode ? app->support_mode : "0");
                __BIND_TEXT(db, stmt, idx++,
                                __get_bool(mfx->support_disable, false));
                __BIND_TEXT(db, stmt, idx++, app->component_type);
@@ -2250,7 +2251,8 @@ static int __insert_package_info(sqlite3 *db, manifest_x *mfx)
        __BIND_TEXT(db, stmt, idx++, mfx->root_path);
        __BIND_TEXT(db, stmt, idx++, mfx->external_path);
        __BIND_TEXT(db, stmt, idx++, mfx->csc_path);
-       __BIND_TEXT(db, stmt, idx++, mfx->support_mode);
+       __BIND_TEXT(db, stmt, idx++,
+                       mfx->support_mode ? mfx->support_mode : "0");
        __BIND_TEXT(db, stmt, idx++, __get_bool(mfx->support_disable, false));
 
        ret = sqlite3_step(stmt);