Fix a static analysis issue
[platform/core/appfw/pkgmgr-info.git] / src / pkgmgrinfo_pkginfo.c
index a9ba8db..a33d1ce 100644 (file)
@@ -385,7 +385,7 @@ static int _pkginfo_get_packages(uid_t uid, const char *locale,
 
        ret = __open_db(dbpath, &db, SQLITE_OPEN_READONLY);
        if (ret != SQLITE_OK) {
-               _LOGD("failed to open db: %d", ret);
+               _LOGD("failed to open db(%s): %d", dbpath, ret);
                free(dbpath);
                return PMINFO_R_ERROR;
        }
@@ -678,7 +678,7 @@ static int _pkgmgrinfo_get_pkginfo(const char *pkgid, uid_t uid,
                                PMINFO_PKGINFO_GET_ALL, list);
 
        if (!g_hash_table_size(list)) {
-               _LOGI("pkginfo for [%s] is not existed for user [%d]",
+               _LOGD("pkginfo for [%s] is not existed for user [%d]",
                                pkgid, uid);
                g_hash_table_destroy(list);
                free(locale);
@@ -807,7 +807,7 @@ API int pkgmgrinfo_pkginfo_get_usr_disabled_pkginfo(const char *pkgid,
        }
 
        if (!g_hash_table_size(list)) {
-               _LOGI("disabled pkginfo for [%s] is not existed for user [%d]",
+               _LOGD("disabled pkginfo for [%s] is not existed for user [%d]",
                                pkgid, uid);
                g_hash_table_destroy(list);
                free(locale);
@@ -1529,8 +1529,6 @@ API int pkgmgrinfo_pkginfo_is_movable(pkgmgrinfo_pkginfo_h handle, bool *movable
        val = (char *)info->pkg_info->installlocation;
        if (strcmp(val, "internal-only") == 0)
                *movable = 0;
-       else if (strcmp(val, "prefer-external") == 0)
-               *movable = 1;
        else
                *movable = 1;