diff options
-rw-r--r-- | src/core/unit.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/core/unit.c b/src/core/unit.c index b091a0999b..f76b6c30a8 100644 --- a/src/core/unit.c +++ b/src/core/unit.c @@ -3154,6 +3154,11 @@ static bool fragment_mtime_newer(const char *path, usec_t mtime, bool path_maske if (!path) return false; + /* If the source is some virtual kernel file system, then we assume we watch it anyway, and hence pretend we + * are never out-of-date. */ + if (PATH_STARTSWITH_SET(path, "/proc", "/sys")) + return false; + if (stat(path, &st) < 0) /* What, cannot access this anymore? */ return true; |