aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/nnn.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/src/nnn.c b/src/nnn.c
index b837959..3d88772 100644
--- a/src/nnn.c
+++ b/src/nnn.c
@@ -3867,10 +3867,7 @@ nochange:
}
if (S_ISREG(sb.st_mode)) {
- if (ndents)
- tmp = dents[cur].name;
- else
- tmp = NULL;
+ tmp = ndents ? dents[cur].name : NULL;
spawn(shell, scriptpath, tmp, path, F_NORMAL | F_SIGINT);
}
break;