mirror of
https://codeberg.org/dnkl/yambar.git
synced 2025-04-23 04:25:42 +02:00
main: S_ISFIFO() matches both pipes and FIFOs
This commit is contained in:
parent
cb2561a72c
commit
bbbf2b601e
2 changed files with 3 additions and 3 deletions
|
@ -18,8 +18,8 @@
|
||||||
* battery: scale option, for batteries that report 'charge' at a
|
* battery: scale option, for batteries that report 'charge' at a
|
||||||
different scale than 'current'.
|
different scale than 'current'.
|
||||||
* network: new `quality` tag (Wi-Fi only).
|
* network: new `quality` tag (Wi-Fi only).
|
||||||
* Read alternative config from pipes (e.g. `--config /dev/stdin`)
|
* Read alternative config from pipes and FIFOs (e.g. `--config
|
||||||
([#340][340]).
|
/dev/stdin`) ([#340][340]).
|
||||||
|
|
||||||
[340]: https://codeberg.org/dnkl/yambar/pulls/340
|
[340]: https://codeberg.org/dnkl/yambar/pulls/340
|
||||||
|
|
||||||
|
|
2
main.c
2
main.c
|
@ -224,7 +224,7 @@ main(int argc, char *const *argv)
|
||||||
fprintf(stderr, "%s: invalid configuration file: %s\n", optarg, strerror(errno));
|
fprintf(stderr, "%s: invalid configuration file: %s\n", optarg, strerror(errno));
|
||||||
return EXIT_FAILURE;
|
return EXIT_FAILURE;
|
||||||
} else if (!S_ISREG(st.st_mode) && !S_ISFIFO(st.st_mode)) {
|
} else if (!S_ISREG(st.st_mode) && !S_ISFIFO(st.st_mode)) {
|
||||||
fprintf(stderr, "%s: invalid configuration file: neither a regular file nor a pipe\n",
|
fprintf(stderr, "%s: invalid configuration file: neither a regular file nor a pipe or FIFO\n",
|
||||||
optarg);
|
optarg);
|
||||||
return EXIT_FAILURE;
|
return EXIT_FAILURE;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue