From 045936a778acc6202d87c16834054e66833eacc3 Mon Sep 17 00:00:00 2001 From: cinap_lenrek Date: Wed, 23 Feb 2022 18:13:00 +0000 Subject: [PATCH] nusb/cam: fix mistake (nil vs -1) --- sys/src/cmd/nusb/cam/video.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) 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);