From 2a1359c4c885be77a7cd15bb3869c7bad1265b9c Mon Sep 17 00:00:00 2001 From: Minje Ahn Date: Fri, 9 Mar 2018 12:58:23 +0900 Subject: [PATCH] Fix for removed file case Change-Id: I36c52f10c9f14cf2a030e129834e05bb3bc38a71 Signed-off-by: Minje Ahn --- src/media_util_private.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/media_util_private.c b/src/media_util_private.c index aee3535..d963500 100755 --- a/src/media_util_private.c +++ b/src/media_util_private.c @@ -88,6 +88,12 @@ int _media_util_check_ignore_file(const char *path, bool *ignore) char replace[MAX_PATH_LEN] = {0, }; #endif + /* Check is exist (It may be the path to the deleted file) */ + if (!g_file_test(path, G_FILE_TEST_EXISTS)) { + media_content_sec_debug("removed path[%s]", path); + return MEDIA_CONTENT_ERROR_NONE; + } + /* Check symbolic link file */ if (g_file_test(path, G_FILE_TEST_IS_SYMLINK)) { *ignore = TRUE; -- 2.34.1