From: Wolfgang Denk Date: Mon, 12 Apr 2004 16:45:36 +0200 Subject: [U-Boot-Users] Hush 'elif' operation? In-Reply-To: Your message of "Fri, 30 Jan 2004 10:04:08 +1300." <40197548.6060001@tait.co.nz> Message-ID: <20040412144541.9D314C109F@atlas.denx.de> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Dear Robin, in message <40197548.6060001@tait.co.nz> you wrote: > > I'm trying to get as close to a switch statement in hush shell language > as possible and thought that a set of if/then/elif/else would be tidier > than nested if/then/else. It doesn't work how I expected however. The ... > =>if iml; then echo "one"; elif iml; then echo "two"; elif iml; then > echo "three"; else echo "four"; fi > Image at 40340000: > Image Name: Linux-2.4.22-20040129-12:57 > Image Type: PowerPC Linux Kernel Image (gzip compressed) > Data Size: 630253 Bytes = 615.5 kB > Load Address: 00000000 > Entry Point: 00000000 > > one > two > three > => I just checked in a patch that fixes this problem. Sorry this took so long. Best regards, Wolfgang Denk -- Software Engineering: Embedded and Realtime Systems, Embedded Linux Phone: (+49)-8142-4596-87 Fax: (+49)-8142-4596-88 Email: wd at denx.de Command, n.: Statement presented by a human and accepted by a computer in such a manner as to make the human feel as if he is in control.