﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	resolution	keywords	cc
306	Inotify follows symlinks instead of monitoring them	rainer	rainer	"The flag IN_DONT_FOLLOW is missing in inotify_add_watch(), which causes inotify to monitor the target rather than the symlink. This is at variance with the behaviour without inotify (reported by [anonymous]).

{{{
--- src/sh_inotify.c~	2012-08-09 19:29:33.524332502 +0200
+++ src/sh_inotify.c	2012-08-09 20:07:04.566452614 +0200
@@ -467,8 +467,12 @@
   return -1;
 }
 
+#if ! defined(IN_DONT_FOLLOW)
+ /* It only exists since Linux 2.6.15. */
+ #define IN_DONT_FOLLOW 0
+#endif
 #define SH_INOTIFY_FILEFLAGS \
-  (IN_ATTRIB|IN_MODIFY|IN_DELETE_SELF|IN_MOVE_SELF|IN_UNMOUNT)
+  (IN_ATTRIB|IN_MODIFY|IN_DELETE_SELF|IN_MOVE_SELF|IN_UNMOUNT|IN_DONT_FOLLOW)
 #define SH_INOTIFY_DIRFLAGS \
   (SH_INOTIFY_FILEFLAGS|IN_DELETE|IN_CREATE|IN_MOVED_FROM|IN_MOVED_TO)
}}}"	defect	closed	major	3.0.6	main		fixed		
