From owner-svn-src-all@FreeBSD.ORG Sun Nov 17 17:48:56 2013 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 02CA591A; Sun, 17 Nov 2013 17:48:56 +0000 (UTC) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id CC4832A1C; Sun, 17 Nov 2013 17:48:55 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id rAHHmtTW095982; Sun, 17 Nov 2013 17:48:55 GMT (envelope-from dteske@svn.freebsd.org) Received: (from dteske@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id rAHHmtvw095980; Sun, 17 Nov 2013 17:48:55 GMT (envelope-from dteske@svn.freebsd.org) Message-Id: <201311171748.rAHHmtvw095980@svn.freebsd.org> From: Devin Teske Date: Sun, 17 Nov 2013 17:48:55 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r258266 - in head/usr.sbin/bsdconfig: packages share/media X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.16 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 17 Nov 2013 17:48:56 -0000 Author: dteske Date: Sun Nov 17 17:48:55 2013 New Revision: 258266 URL: http://svnweb.freebsd.org/changeset/base/258266 Log: Always shutdown the media when we're exiting the packages module (prevents errors on re-entry for physical media). Also, while we're here, stop ejecting the CDROM when we're done with it (but leave the functions for later use so that we could perhaps -- from the installer standpoint -- use it to eject the media after an install). MFC after: 3 days Modified: head/usr.sbin/bsdconfig/packages/packages head/usr.sbin/bsdconfig/share/media/cdrom.subr Modified: head/usr.sbin/bsdconfig/packages/packages ============================================================================== --- head/usr.sbin/bsdconfig/packages/packages Sun Nov 17 17:42:15 2013 (r258265) +++ head/usr.sbin/bsdconfig/packages/packages Sun Nov 17 17:48:55 2013 (r258266) @@ -38,6 +38,7 @@ BSDCFG_SHARE="/usr/share/bsdconfig" . $BSDCFG_SHARE/common.subr || exit 1 f_dprintf "%s: loading includes..." "$0" f_include $BSDCFG_SHARE/dialog.subr +f_include $BSDCFG_SHARE/media/common.subr f_include $BSDCFG_SHARE/mustberoot.subr f_include $BSDCFG_SHARE/packages/packages.subr @@ -73,6 +74,7 @@ f_device_get_all # # Display the package configuration menu and exit # +trap 'f_media_close' EXIT f_package_config ################################################################################ Modified: head/usr.sbin/bsdconfig/share/media/cdrom.subr ============================================================================== --- head/usr.sbin/bsdconfig/share/media/cdrom.subr Sun Nov 17 17:42:15 2013 (r258265) +++ head/usr.sbin/bsdconfig/share/media/cdrom.subr Sun Nov 17 17:48:55 2013 (r258266) @@ -163,8 +163,7 @@ f_media_get_cdrom() # f_media_shutdown_cdrom $device # -# Shuts down the CDROM device and ejects the media using f_media_eject_cdrom(), -# below. Return status should be ignored. +# Shuts down the CDROM device. Return status should be ignored. # f_media_shutdown_cdrom() { @@ -184,8 +183,6 @@ f_media_shutdown_cdrom() else CDROM_MOUNTED= fi - - f_media_eject_cdrom "$dev" } # f_media_eject_cdrom $device