From mboxrd@z Thu Jan  1 00:00:00 1970
Received: from pigeon.gentoo.org ([208.92.234.80] helo=lists.gentoo.org)
	by finch.gentoo.org with esmtp (Exim 4.60)
	(envelope-from <gentoo-commits+bounces-437895-garchives=archives.gentoo.org@lists.gentoo.org>)
	id 1S6ZPT-0006gh-DQ
	for garchives@archives.gentoo.org; Sun, 11 Mar 2012 03:25:27 +0000
Received: from pigeon.gentoo.org (localhost [127.0.0.1])
	by pigeon.gentoo.org (Postfix) with SMTP id 8D204E05EF;
	Sun, 11 Mar 2012 03:25:19 +0000 (UTC)
Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183])
	by pigeon.gentoo.org (Postfix) with ESMTP id 5737AE05EF
	for <gentoo-commits@lists.gentoo.org>; Sun, 11 Mar 2012 03:25:19 +0000 (UTC)
Received: from hornbill.gentoo.org (hornbill.gentoo.org [94.100.119.163])
	(using TLSv1 with cipher AECDH-AES256-SHA (256/256 bits))
	(No client certificate requested)
	by smtp.gentoo.org (Postfix) with ESMTPS id B93DC1B4029
	for <gentoo-commits@lists.gentoo.org>; Sun, 11 Mar 2012 03:25:18 +0000 (UTC)
Received: from localhost.localdomain (localhost [127.0.0.1])
	by hornbill.gentoo.org (Postfix) with ESMTP id 81350E5402
	for <gentoo-commits@lists.gentoo.org>; Sun, 11 Mar 2012 03:25:17 +0000 (UTC)
From: "Mike Frysinger" <vapier@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Content-type: text/plain; charset=UTF-8
Reply-To: gentoo-dev@lists.gentoo.org, "Mike Frysinger" <vapier@gentoo.org>
Message-ID: <1331436205.a78ec9a7e6b4a0dd6e565913db35e436f67553ff.vapier@gentoo>
Subject: [gentoo-commits] proj/portage:master commit in: bin/
X-VCS-Repository: proj/portage
X-VCS-Files: bin/etc-update
X-VCS-Directories: bin/
X-VCS-Committer: vapier
X-VCS-Committer-Name: Mike Frysinger
X-VCS-Revision: a78ec9a7e6b4a0dd6e565913db35e436f67553ff
X-VCS-Branch: master
Date: Sun, 11 Mar 2012 03:25:17 +0000 (UTC)
Precedence: bulk
List-Post: <mailto:gentoo-commits@lists.gentoo.org>
List-Help: <mailto:gentoo-commits+help@lists.gentoo.org>
List-Unsubscribe: <mailto:gentoo-commits+unsubscribe@lists.gentoo.org>
List-Subscribe: <mailto:gentoo-commits+subscribe@lists.gentoo.org>
List-Id: Gentoo Linux mail <gentoo-commits.gentoo.org>
X-BeenThere: gentoo-commits@lists.gentoo.org
Content-Transfer-Encoding: quoted-printable
X-Archives-Salt: df764d47-a407-4b65-ba84-a4c1e78896de
X-Archives-Hash: a16b70bc0ab20c8492c811b25ea0eae5

commit:     a78ec9a7e6b4a0dd6e565913db35e436f67553ff
Author:     Mike Frysinger <vapier <AT> gentoo <DOT> org>
AuthorDate: Sun Mar 11 03:23:25 2012 +0000
Commit:     Mike Frysinger <vapier <AT> gentoo <DOT> org>
CommitDate: Sun Mar 11 03:23:25 2012 +0000
URL:        http://git.overlays.gentoo.org/gitweb/?p=3Dproj/portage.git;a=
=3Dcommit;h=3Da78ec9a7

etc-update: fix default "enter" behavior

Adding support for -[3579] command line flags inadvertently broke the
default behavior of hitting "enter" to automatically select the next
file.  Make this work again.

Signed-off-by: Mike Frysinger <vapier <AT> gentoo.org>

---
 bin/etc-update |    7 +++++--
 1 files changed, 5 insertions(+), 2 deletions(-)

diff --git a/bin/etc-update b/bin/etc-update
index cd63ae1..7b05f11 100755
--- a/bin/etc-update
+++ b/bin/etc-update
@@ -236,10 +236,13 @@ sel_file() {
 					|| die "$(<"${TMP}"/input)\n\nUser termination!" 0
 				input=3D$(<"${TMP}"/input)
 			fi
+			: ${input:=3D0}
=20
-			parse_automode_flag ${input} || continue
+			if [[ ${input} !=3D 0 ]] ; then
+				parse_automode_flag ${input} || continue
+			fi
 		fi # -3 automerge
-		if [[ ${input:-0} =3D=3D 0 ]] ; then
+		if [[ ${input} =3D=3D 0 ]] ; then
 			input=3D${isfirst}
 		fi
 	done