This commit is contained in:
Arun Prakash Jana 2020-05-20 18:46:12 +05:30
parent c6c1514c6b
commit 9e41c39138
No known key found for this signature in database
GPG Key ID: A75979F35C080412
1 changed files with 4 additions and 6 deletions

View File

@ -4731,17 +4731,15 @@ static void notify_fifo()
} }
} }
static char *name = NULL; static struct entry lastentry = {0};
static time_t t = {0};
if (dents[cur].name == name && dents[cur].t == t) if (!memcmp(&lastentry, &dents[cur], sizeof(struct entry)))
return; return;
name = dents[cur].name; lastentry = dents[cur];
t = dents[cur].t;
char path[PATH_MAX]; char path[PATH_MAX];
size_t len = mkpath(g_ctx[cfg.curctx].c_path, ndents ? name : "", path); size_t len = mkpath(g_ctx[cfg.curctx].c_path, ndents ? dents[cur].name : "", path);
path[len - 1] = '\n'; path[len - 1] = '\n';