Remove unused parameter 01/199201/2 accepted/tizen/unified/20190208.061626 submit/tizen/20190207.065213
authorhj kim <backto.kim@samsung.com>
Thu, 7 Feb 2019 06:32:51 +0000 (15:32 +0900)
committerhj kim <backto.kim@samsung.com>
Thu, 7 Feb 2019 06:39:39 +0000 (15:39 +0900)
Change-Id: I01d98e671a5e0828ef03d89823fe5693e278c0e5

lib/media-util-user.c

index 934d86b..da90b19 100755 (executable)
@@ -54,7 +54,7 @@ bool _ms_is_support_senior_mode()
 }
 #endif
 
-static int __ms_user_get_path(ms_user_path_type_e type, const char *storage_id, uid_t uid, char **path)
+static int __ms_user_get_path(ms_user_path_type_e type, uid_t uid, char **path)
 {
        int ret = MS_MEDIA_ERR_NONE;
        const char *result = NULL;
@@ -124,7 +124,7 @@ int ms_user_get_internal_root_path(uid_t uid, char **path)
        if (uid == getuid())
                *path = g_strndup(MEDIA_ROOT_PATH_INTERNAL, strlen(MEDIA_ROOT_PATH_INTERNAL));
        else
-               ret = __ms_user_get_path(INTERNAL_ROOT, NULL, uid, path);
+               ret = __ms_user_get_path(INTERNAL_ROOT, uid, path);
 
        //MSAPI_DBG_SLOG("internal root path [%s]", *path);
 
@@ -153,6 +153,7 @@ int ms_user_get_storage_type(uid_t uid, const char *path, ms_user_storage_type_e
 
        ret = ms_user_get_internal_root_path(uid, &internal_path);
        MSAPI_RETVM_IF(ret != MS_MEDIA_ERR_NONE, ret, "Fail get internal root path");
+       MSAPI_RETVM_IF(internal_path == NULL, ret, "Fail get internal root path (NULL)");
 
        path_len = strlen(internal_path);
 
@@ -181,7 +182,7 @@ int ms_user_get_root_thumb_store_path(uid_t uid, char **path)
        if (uid == getuid())
                *path = g_strdup(tzplatform_mkpath(TZ_USER_SHARE, "media/.thumb"));
        else
-               ret = __ms_user_get_path(THUMB_ROOT, NULL, uid, path);
+               ret = __ms_user_get_path(THUMB_ROOT, uid, path);
 
        //MSAPI_DBG_SLOG("thumb path [%s]", *path);
 
@@ -195,7 +196,7 @@ int ms_user_get_media_db_path(uid_t uid, char **path)
        if (uid == getuid())
                *path = g_strdup(tzplatform_mkpath(TZ_USER_DB, ".media.db"));
        else
-               ret = __ms_user_get_path(MEDIA_DB, NULL, uid, path);
+               ret = __ms_user_get_path(MEDIA_DB, uid, path);
 
        //MSAPI_DBG_SLOG("DB path [%s]", *path);
 
@@ -210,7 +211,7 @@ int ms_user_get_mediashared_path(uid_t uid, char **path)
        if (uid == getuid())
                *path = g_strdup(tzplatform_getenv(TZ_USER_MEDIASHARED));
        else
-               ret = __ms_user_get_path(MEDIA_SHARED, NULL, uid, path);
+               ret = __ms_user_get_path(MEDIA_SHARED, uid, path);
 
        //MSAPI_DBG_SLOG("DB path [%s]", *path);