inotify: Change inotify mask.
authorAlok Barsode <alok.barsode@linux.intel.com>
Thu, 5 Jan 2012 12:41:10 +0000 (14:41 +0200)
committerDaniel Wagner <daniel.wagner@bmw-carit.de>
Mon, 9 Jan 2012 15:07:37 +0000 (16:07 +0100)
Use IN_CLOSE_WRITE instead of IN_MODIFY so the notifier
is called once only after all the changes are written.

Fixes BMC#23741.

src/timezone.c

index d82502b..37d71a0 100644 (file)
@@ -420,7 +420,7 @@ int __connman_timezone_init(void)
        dirname = g_path_get_dirname(ETC_LOCALTIME);
 
        wd = inotify_add_watch(fd, dirname, IN_DONT_FOLLOW |
-                                               IN_MODIFY | IN_MOVED_TO);
+                                               IN_CLOSE_WRITE | IN_MOVED_TO);
 
        g_free(dirname);