summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorcinap_lenrek <cinap_lenrek@felloff.net>2022-02-23 18:13:00 +0000
committercinap_lenrek <cinap_lenrek@felloff.net>2022-02-23 18:13:00 +0000
commit045936a778acc6202d87c16834054e66833eacc3 (patch)
treeefa74467c597cebb0ffba68b62a361b3c408c38e /sys
parent8bf71adc94af5c17bdb176a5e6e1a56dbe725715 (diff)
nusb/cam: fix mistake (nil vs -1)
Diffstat (limited to 'sys')
-rw-r--r--sys/src/cmd/nusb/cam/video.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/src/cmd/nusb/cam/video.c b/sys/src/cmd/nusb/cam/video.c
index 507093651..ce89427bb 100644
--- a/sys/src/cmd/nusb/cam/video.c
+++ b/sys/src/cmd/nusb/cam/video.c
@@ -278,7 +278,7 @@ err:
if(usbcmd(d, 0x21, SET_CUR, VS_COMMIT_CONTROL << 8, c->iface->id, (uchar *) &c->pc, sizeof(ProbeControl)) < sizeof(ProbeControl)) goto err;
e = selbw(c, &c->pc, d->usb->ep[c->hdr->bEndpointAddress & Epmax]);
if(e == nil || setalt(c->dev, e->iface) < 0)
- return nil;
+ return -1;
c->ep = openep(d, e);
if(c->ep == nil){
setalt(d, c->iface);