summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJonathan Gray <jsg@cvs.openbsd.org>2015-01-04 08:42:05 +0000
committerJonathan Gray <jsg@cvs.openbsd.org>2015-01-04 08:42:05 +0000
commitfe8ce511050505f4da828a7fa6ac9cbda41e2d08 (patch)
treec53471d5bcc3c10b6d60c40e3c399dc67dc28973
parent62135d534772ff701fc71ba33ec329a5acb9c05f (diff)
return 0 for success in ucycom_param() instead of uninitialised memory
-rw-r--r--sys/dev/usb/ucycom.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/sys/dev/usb/ucycom.c b/sys/dev/usb/ucycom.c
index 50c31f32b33..a75c1fd484f 100644
--- a/sys/dev/usb/ucycom.c
+++ b/sys/dev/usb/ucycom.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ucycom.c,v 1.31 2014/12/11 18:55:15 mpi Exp $ */
+/* $OpenBSD: ucycom.c,v 1.32 2015/01/04 08:42:04 jsg Exp $ */
/* $NetBSD: ucycom.c,v 1.3 2005/08/05 07:27:47 skrll Exp $ */
/*
@@ -380,7 +380,6 @@ ucycom_param(void *addr, int portno, struct termios *t)
uint8_t report[5];
uint32_t baud = 0;
uint8_t cfg;
- int err;
if (usbd_is_dying(sc->sc_udev))
return (EIO);
@@ -452,7 +451,7 @@ ucycom_param(void *addr, int portno, struct termios *t)
sc->sc_hdev.sc_report_id, report, sc->sc_flen) != sc->sc_flen)
return EIO;
sc->sc_baud = baud;
- return (err);
+ return (0);
}
void