Svace issue fix 88/126888/1
authorHaejeong Kim <backto.kim@samsung.com>
Tue, 25 Apr 2017 08:09:39 +0000 (17:09 +0900)
committerHaejeong Kim <backto.kim@samsung.com>
Tue, 25 Apr 2017 08:09:39 +0000 (17:09 +0900)
Change-Id: Ibba3474098762bcdfda7eeb98373cd663ae9dd34

src/media_util_private.c

index 1b2151222504962c0856dd7c2fb06fc930930b95..15b4bdde6ac41c590fae6c2054406d9507401ef5 100755 (executable)
@@ -148,7 +148,7 @@ int _media_util_check_ignore_dir(const char *dir_path, bool *ignore)
                                bool is_root = FALSE;
 
                                parent_folder_path = g_path_get_dirname(search_path);
-                               if (STRING_VALID(MEDIA_ROOT_PATH_USB) && (strcmp(parent_folder_path, MEDIA_ROOT_PATH_USB) == 0))
+                               if (STRING_VALID(MEDIA_ROOT_PATH_USB) && STRING_VALID(parent_folder_path) && (strcmp(parent_folder_path, MEDIA_ROOT_PATH_USB) == 0))
                                        is_root = TRUE;
 
                                SAFE_FREE(parent_folder_path);