sigap

Simplest audio player possible bundled signal based queue manager
Log | Files | Refs | README | LICENSE

commit 3bf725a355e638cf0351887a603b85b9fc81daa8
parent 63b4cd03d730f2555450694d5b97fefcbcbeb789
Author: Jacob R. Edwards <jacobouno@protonmail.com>
Date:   Thu, 15 Jul 2021 15:08:02 -0700

Check for bad file descriptor in apfd

Diffstat:
Mapfd.c | 3+++
1 file changed, 3 insertions(+), 0 deletions(-)

diff --git a/apfd.c b/apfd.c @@ -50,6 +50,9 @@ apfd(int fd) #ifdef POLL struct pollfd pfd; + if (fd < 0) + return strerror(EBADF); + pfd.fd = fd; pfd.events = POLLIN; if (poll(&pfd, 1, INFTIM) == -1)