From: michael Date: Thu, 15 Mar 2007 08:29:53 +0000 (+0000) Subject: always set ecpbase correctly. X-Git-Url: https://git.zerfleddert.de/cgi-bin/gitweb.cgi/usb-driver/commitdiff_plain/57fade8e359a0868939de153436a58bd7d0bd098 always set ecpbase correctly. --- diff --git a/usb-driver.c b/usb-driver.c index 7523c13..1c5b18b 100644 --- a/usb-driver.c +++ b/usb-driver.c @@ -360,6 +360,7 @@ int do_wdioctl(int fd, unsigned int request, unsigned char *wdioctl) { if (ioctl(parportfd, PPCLAIM) == -1) return ret; + ecpbase = 0; pmode = IEEE1284_MODE_COMPAT; if (ioctl(parportfd, PPNEGOT, &pmode) == -1) return ret; @@ -372,6 +373,7 @@ int do_wdioctl(int fd, unsigned int request, unsigned char *wdioctl) { pmode = IEEE1284_MODE_ECP; if (ioctl(parportfd, PPNEGOT, &pmode) == -1) { + ecpbase = 0; pmode = IEEE1284_MODE_COMPAT; if (ioctl(parportfd, PPNEGOT, &pmode) == -1) return ret;