X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?p=elogind.git;a=blobdiff_plain;f=src%2Fpath.c;h=1455b47995e4943f2bf3affb10d8b558e2fa3951;hp=77de32d1d6e8442fbe9b6ed4ee5e2042861c6267;hb=3fc546f93d92c09188d5018ea47def33b149c2e9;hpb=67575eef76e99cc03b2860f8a93009a34ce37583 diff --git a/src/path.c b/src/path.c index 77de32d1d..1455b4799 100644 --- a/src/path.c +++ b/src/path.c @@ -223,9 +223,9 @@ static int path_watch_one(Path *p, PathSpec *s) { /* Trim the path at the last slash. Keep the slash if it's the root dir. */ slash[slash == k] = 0; - flags = IN_DELETE_SELF|IN_MOVE_SELF|IN_ATTRIB; + flags = IN_MOVE_SELF; if (!exists) - flags |= IN_CREATE | IN_MOVED_TO; + flags |= IN_DELETE_SELF | IN_ATTRIB | IN_CREATE | IN_MOVED_TO; if (inotify_add_watch(s->inotify_fd, k, flags) >= 0) exists = true; @@ -279,7 +279,7 @@ static void path_set_state(Path *p, PathState state) { path_state_to_string(old_state), path_state_to_string(state)); - unit_notify(UNIT(p), state_translation_table[old_state], state_translation_table[state]); + unit_notify(UNIT(p), state_translation_table[old_state], state_translation_table[state], true); } static void path_enter_waiting(Path *p, bool initial, bool recheck);