summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorAaron Campbell <aaron@cvs.openbsd.org>2000-09-07 20:38:57 +0000
committerAaron Campbell <aaron@cvs.openbsd.org>2000-09-07 20:38:57 +0000
commitf044a53cd0da1e1566efd0a31c94d4e73e5be814 (patch)
tree6298316317f81e55723018758063ff489b84c13c /sys
parentff09195ca45419f19d427261e0105b42b8ef627c (diff)
Put back a fix that fgsch@ whacked during the last NetBSD USB sync:
If the vendor name is NULL, do not output a leading space; reported by deraadt@
Diffstat (limited to 'sys')
-rw-r--r--sys/dev/usb/usb_subr.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/dev/usb/usb_subr.c b/sys/dev/usb/usb_subr.c
index b7c1f8a867c..9e34225bea1 100644
--- a/sys/dev/usb/usb_subr.c
+++ b/sys/dev/usb/usb_subr.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: usb_subr.c,v 1.12 2000/07/04 11:44:25 fgsch Exp $ */
+/* $OpenBSD: usb_subr.c,v 1.13 2000/09/07 20:38:56 aaron Exp $ */
/* $NetBSD: usb_subr.c,v 1.72 2000/04/14 14:13:56 augustss Exp $ */
/* $FreeBSD: src/sys/dev/usb/usb_subr.c,v 1.18 1999/11/17 22:33:47 n_hibma Exp $ */
@@ -283,7 +283,7 @@ usbd_devinfo(dev, showclass, cp)
int bcdDevice, bcdUSB;
usbd_devinfo_vp(dev, vendor, product);
- cp += sprintf(cp, "%s %s", vendor, product);
+ cp += sprintf(cp, "%s%s%s", vendor, *vendor ? " " : "", product);
if (showclass)
cp += sprintf(cp, ", class %d/%d",
udd->bDeviceClass, udd->bDeviceSubClass);