From owner-freebsd-bugs@FreeBSD.ORG Sun May 25 20:10:14 2003 Return-Path: Delivered-To: freebsd-bugs@hub.freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 504EB37B404 for ; Sun, 25 May 2003 20:10:14 -0700 (PDT) Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id E36A443FAF for ; Sun, 25 May 2003 20:10:09 -0700 (PDT) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.12.9/8.12.9) with ESMTP id h4Q3A9Up032145 for ; Sun, 25 May 2003 20:10:09 -0700 (PDT) (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.12.9/8.12.9/Submit) id h4Q3A9tM032144; Sun, 25 May 2003 20:10:09 -0700 (PDT) Resent-Date: Sun, 25 May 2003 20:10:09 -0700 (PDT) Resent-Message-Id: <200305260310.h4Q3A9tM032144@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Alexander Nedotsukov Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id D944A37B401; Sun, 25 May 2003 20:04:09 -0700 (PDT) Received: from bbnest.dyndns.org (n237099.ap.plala.or.jp [219.165.237.99]) by mx1.FreeBSD.org (Postfix) with ESMTP id 06C2A43F93; Sun, 25 May 2003 20:04:09 -0700 (PDT) (envelope-from bland@mail.ru) Received: from bbnest.dyndns.org (bland@localhost [127.0.0.1]) by bbnest.dyndns.org (8.12.9/8.12.9) with ESMTP id h4Q348Zj088521; Mon, 26 May 2003 12:04:08 +0900 (JST) (envelope-from bland@mail.ru) Received: (from bland@localhost) by bbnest.dyndns.org (8.12.9/8.12.9/Submit) id h4Q347QZ088520; Mon, 26 May 2003 12:04:07 +0900 (JST) (envelope-from bland) Message-Id: <200305260304.h4Q347QZ088520@bbnest.dyndns.org> Date: Mon, 26 May 2003 12:04:07 +0900 (JST) From: Alexander Nedotsukov To: FreeBSD-gnats-submit@FreeBSD.org X-Send-Pr-Version: 3.113 cc: mdodd@FreeBSD.org Subject: bin/52685: variable used uninitialized in usbhidctl X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: Alexander Nedotsukov List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 26 May 2003 03:10:14 -0000 >Number: 52685 >Category: bin >Synopsis: variable used uninitialized in usbhidctl >Confidential: no >Severity: serious >Priority: medium >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: change-request >Submitter-Id: current-users >Arrival-Date: Sun May 25 20:10:09 PDT 2003 >Closed-Date: >Last-Modified: >Originator: Alexander Nedotsukov >Release: FreeBSD 5.1-BETA i386 >Organization: >Environment: System: FreeBSD bbnest.dyndns.org 5.1-BETA FreeBSD 5.1-BETA #5: Sat May 10 21:37:53 JST 2003 bland@bbnest.dyndns.org:/usr/obj/usr/src/sys/SU i386 >Description: Local variable report_id is never initialized before use. See dumpdata() function. >How-To-Repeat: >Fix: Apply the patch attached. --- usbhid.c.diff begins here --- --- usr.bin/usbhidctl/usbhid.c.orig Mon May 26 11:42:36 2003 +++ usr.bin/usbhidctl/usbhid.c Mon May 26 11:45:07 2003 @@ -201,7 +201,6 @@ static int one = 1; u_int32_t colls[100]; int sp = 0; - int report_id; char namebuf[10000], *namep; hids = 0; @@ -245,7 +244,7 @@ if (all || gotname(namebuf)) { if (!noname) printf("%s=", namebuf); - prdata(dbuf + (report_id != 0), n); + prdata(dbuf + (reportid != 0), n); printf("\n"); } } --- usbhid.c.diff ends here --- >Release-Note: >Audit-Trail: >Unformatted: