From owner-cvs-all Thu Oct 17 11:34:43 2002 Delivered-To: cvs-all@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 3A21737B401; Thu, 17 Oct 2002 11:34:42 -0700 (PDT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id DE79743E91; Thu, 17 Oct 2002 11:34:41 -0700 (PDT) (envelope-from sam@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.12.6/8.12.6) with ESMTP id g9HIYWmV075104; Thu, 17 Oct 2002 11:34:32 -0700 (PDT) (envelope-from sam@repoman.freebsd.org) Received: (from sam@localhost) by repoman.freebsd.org (8.12.6/8.12.6/Submit) id g9HIYW8u075103; Thu, 17 Oct 2002 11:34:32 -0700 (PDT) Message-Id: <200210171834.g9HIYW8u075103@repoman.freebsd.org> From: Sam Leffler Date: Thu, 17 Oct 2002 11:34:32 -0700 (PDT) To: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org Subject: cvs commit: src/lib/libdisk disk.c X-FreeBSD-CVS-Branch: HEAD Sender: owner-cvs-all@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG sam 2002/10/17 11:34:32 PDT Modified files: lib/libdisk disk.c Log: o ioctl DIOCGDINFO error wasn't checked o memory wasn't reclaimed in certain cases o add more msgs under #ifdef DEBUG o rewrite tangle of for loops for clarity NB: Open_Disk should redo how it malloc's memory so the caller can free everything. Documentation says the caller can free the disk list to reclaim everything but this leaks the indirect strings. Fixing this is simple for the sysctl case but adds complexity to the fallback, non-sysctl, case. Revision Changes Path 1.81 +29 -7 src/lib/libdisk/disk.c To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message