diff options
author | Lazaros Koromilas <lostd@2f30.org> | 2018-02-25 12:29:36 +0200 |
---|---|---|
committer | Lazaros Koromilas <lostd@2f30.org> | 2018-02-25 12:29:36 +0200 |
commit | 7810f5bd84f81cdc5d32fc35e67162316a7de94f (patch) | |
tree | 29ebbdf2dcdcedb996751c2c9c726c374081c529 /noice.c | |
parent | fef811921b50a2e4a3501e4cef47286c855b4727 (diff) | |
download | noice-7810f5bd84f81cdc5d32fc35e67162316a7de94f.tar.gz |
Return early when dir or filter result empty
Diffstat (limited to 'noice.c')
-rw-r--r-- | noice.c | 2 |
1 files changed, 2 insertions, 0 deletions
@@ -529,6 +529,8 @@ populate(char *path, char *oldpath, char *fltr) ndents = dentfill(path, &dents, visible, &re); freefilter(&re); + if (ndents == 0) + return 0; /* Empty result */ qsort(dents, ndents, sizeof(*dents), entrycmp); |