diff options
| author | 2025-10-20 17:15:37 +0200 | |
|---|---|---|
| committer | 2025-10-20 17:15:37 +0200 | |
| commit | 7d5361374ad0cbe64c6dbb8cce3fc8842ed6b066 (patch) | |
| tree | 859f862c0c27d8424dbeef4c5a774d411e84f32b /main.c | |
| parent | bd3caaa6a0a18bf3cd7038d97c7367b0282146d5 (diff) | |
io: reject non file files
Diffstat (limited to 'main.c')
| -rw-r--r-- | main.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -105,7 +105,7 @@ optparse(char **args) while ((arg = *++args)) { if (*arg++ != '-' || !*arg) { assert(task.ninf < arraylength(task.inf) && "too many infiles"); - task.inf[task.ninf] = *arg ? arg-1 : "/dev/stdin"; + task.inf[task.ninf] = arg[-1] != '-' ? arg-1 : "/dev/stdin"; task.inft[task.ninf] = ft ? ft : ftdetect(arg-1); ++task.ninf; ft = IFTauto; |