From 34b0c22e461edf300e39e858e6ad058bf9adaeef Mon Sep 17 00:00:00 2001 From: Julien BLACHE Date: Thu, 11 Jun 2009 13:51:19 +0200 Subject: [PATCH] Handle symlink-to-directory creation --- src/filescanner.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/filescanner.c b/src/filescanner.c index b61ca3c1..156e00d4 100644 --- a/src/filescanner.c +++ b/src/filescanner.c @@ -744,6 +744,14 @@ process_inotify_file(struct watch_info *wi, char *path, struct inotify_event *ie { DPRINTF(E_LOG, L_SCAN, "Could not stat() '%s': %s\n", file, strerror(errno)); + free(deref); + return; + } + + if (S_ISDIR(sb.st_mode)) + { + process_inotify_dir(wi, deref, ie); + free(deref); return; }