From: michael Date: Sun, 4 Mar 2007 20:32:32 +0000 (+0000) Subject: BUG-Fix: Do not do ioctls on fd == 0 X-Git-Url: https://git.zerfleddert.de/cgi-bin/gitweb.cgi/usb-driver/commitdiff_plain/f0bfb2db7dd53c2ac7c8376805ad596d080bddc8 BUG-Fix: Do not do ioctls on fd == 0 --- diff --git a/usb-driver.c b/usb-driver.c index be08eff..d38da3e 100644 --- a/usb-driver.c +++ b/usb-driver.c @@ -660,7 +660,7 @@ int ioctl(int fd, int request, ...) { argp = va_arg (args, void *); va_end (args); - if (fd == windrvrfd) + if (windrvrfd && (fd == windrvrfd)) ret = do_wdioctl(fd, request, argp); else ret = (*ioctl_func) (fd, request, argp);