aboutsummaryrefslogtreecommitdiffstats
path: root/noice.c
diff options
context:
space:
mode:
authorlostd <lostd@2f30.org>2014-10-07 14:07:56 +0000
committerlostd <>2014-10-07 14:07:56 +0000
commit4384f09726a3178ee6c9c38d0c357068d66140a2 (patch)
treef8ef18cf09fc8a61102a1a3ae868b770995fe6c5 /noice.c
parent908e43cc67f29456bd1abbb0bd4eaa838b10eb8b (diff)
downloadnoice-4384f09726a3178ee6c9c38d0c357068d66140a2.tar.gz
Fix the empty dir bug
Diffstat (limited to 'noice.c')
-rw-r--r--noice.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/noice.c b/noice.c
index 0acd4cb..549eaa3 100644
--- a/noice.c
+++ b/noice.c
@@ -330,6 +330,10 @@ nochange:
char *ext, *bin;
pid_t pid;
+ /* Cannot descend in empty directories */
+ if (n == 0)
+ goto nochange;
+
name = dents[cur]->d_name;
switch (dents[cur]->d_type) {
Un proyecto texto-plano.xyz