Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 24 Jan 2010 02:33:14 +0000 (UTC)
From:      Doug Barton <dougb@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-user@freebsd.org
Subject:   svn commit: r202907 - user/dougb/portmaster
Message-ID:  <201001240233.o0O2XEOg091215@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: dougb
Date: Sun Jan 24 02:33:14 2010
New Revision: 202907
URL: http://svn.freebsd.org/changeset/base/202907

Log:
  When I was twiddling update_port() previously I forgot to restore
  a test for the presence of the $update_to argument. The effect was
  cosmetic, but needed to be fixed.
  
  In post_config(), simplify some of the new code related to the terminal
  title string, and move a local statement down inside the test where
  the variable will be used.

Modified:
  user/dougb/portmaster/portmaster

Modified: user/dougb/portmaster/portmaster
==============================================================================
--- user/dougb/portmaster/portmaster	Sun Jan 24 02:10:23 2010	(r202906)
+++ user/dougb/portmaster/portmaster	Sun Jan 24 02:33:14 2010	(r202907)
@@ -1685,7 +1685,7 @@ update_build_l () {
 update_port () {
 	local update_to
 
-	update_to=" to $2"
+	[ -n "$2" ] && update_to=" to $2"
 	echo "===>>> Launching child to update ${1#$pd/}${update_to}"
 
 	dep_of_deps=$(( $dep_of_deps + 1 ))
@@ -1944,13 +1944,14 @@ create_master_rb_list () {
 }
 
 post_config () {
-	local numdeps answer action
+	local action
 
 	if [ $num_of_deps -gt 0 ]; then
-		numdeps=" (${num_of_deps})"
-		term_printf "$numdeps"
+		term_printf " (${num_of_deps})"
 
 		if [ -z "$PM_NO_CONFIRM" ]; then
+			local answer
+
 			echo ''
 echo "===>>> The following actions will be taken if you choose to proceed:"
 			echo -e "$build_l"



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201001240233.o0O2XEOg091215>