Return for internal storage type in storage_get_type_dev 84/98884/2 accepted/tizen/3.0/common/20161123.140525 accepted/tizen/3.0/ivi/20161123.082814 accepted/tizen/3.0/mobile/20161123.082719 accepted/tizen/3.0/tv/20161123.082739 accepted/tizen/3.0/wearable/20161123.082752 submit/tizen_3.0/20161121.105249
authorpr.jung <pr.jung@samsung.com>
Mon, 21 Nov 2016 04:57:57 +0000 (13:57 +0900)
committerJung <pr.jung@samsung.com>
Mon, 21 Nov 2016 09:25:19 +0000 (01:25 -0800)
Change-Id: I54f562eac2f1639f2e377994af1f4a9c8a26b47e
Signed-off-by: pr.jung <pr.jung@samsung.com>
src/storage-external-dbus.c
src/storage-inhouse.c

index f389391..a3a7c52 100755 (executable)
@@ -410,8 +410,10 @@ int storage_ext_get_device_info(int storage_id, storage_ext_device *info)
                                &info->readonly, &info->mount_point,
                                &info->state, &info->primary,
                                &info->flags, &info->storage_id);
-       } else
+       } else {
+               _E("No storage with the storage id (%d)", storage_id); //LCOV_EXCL_LINE
                return -ENODEV;
+       }
 
        g_variant_unref(result);
 
index 7b89923..23ebb18 100755 (executable)
@@ -194,6 +194,8 @@ API int storage_get_type_dev(int storage_id, storage_type_e *type, storage_dev_e
                _E("Failed to get storage type: %d", ret);
                return ret;
        }
+       if (*type == STORAGE_TYPE_INTERNAL)
+               return STORAGE_ERROR_NONE;
 
        ext_dev = calloc(1, sizeof(storage_ext_device));
        if (!ext_dev) {