From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:38082) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WQHXy-0004So-0L for qemu-devel@nongnu.org; Wed, 19 Mar 2014 10:32:50 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WQHXt-0001St-3K for qemu-devel@nongnu.org; Wed, 19 Mar 2014 10:32:45 -0400 Received: from mx1.redhat.com ([209.132.183.28]:28571) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WQHXs-0001Sh-Qs for qemu-devel@nongnu.org; Wed, 19 Mar 2014 10:32:41 -0400 Message-ID: <5329AA84.8010209@redhat.com> Date: Wed, 19 Mar 2014 08:32:36 -0600 From: Eric Blake MIME-Version: 1.0 References: <5e57ec8dce227b3095dd476e893137f2b14c0d81.1395105370.git.jcody@redhat.com> <20140319133925.GA3019@irqsave.net> <20140319141948.GA4189@localhost.localdomain> <5329A977.5030801@redhat.com> In-Reply-To: <5329A977.5030801@redhat.com> Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="lvRtR5tTvPXN9SqK8eAlXnSjcjT5mIaHC" Subject: Re: [Qemu-devel] [PATCH 1/4] block: qemu-iotests - add common.qemu, for bash-controlled qemu tests List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Jeff Cody , =?UTF-8?B?QmVub8OudCBDYW5ldA==?= Cc: kwolf@redhat.com, qemu-devel@nongnu.org, stefanha@redhat.com This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --lvRtR5tTvPXN9SqK8eAlXnSjcjT5mIaHC Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable On 03/19/2014 08:28 AM, Eric Blake wrote: > $ dash -c 'set 1 2 3; echo ${@: -1}' > dash: 1: Bad substitution >=20 > If you want the last argument, you'll have to do something hideous like= : >=20 > eval \${$#} >=20 > Short of using eval, there is no portable way to get at the last > positional argument in dash. If you are sure you don't need the other positional arguments, you could avoid eval with: shift $(($# - 1)); echo $1 --=20 Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org --lvRtR5tTvPXN9SqK8eAlXnSjcjT5mIaHC Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 Comment: Public key at http://people.redhat.com/eblake/eblake.gpg Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/ iQEcBAEBCAAGBQJTKaqFAAoJEKeha0olJ0Nqy28H/jUjPSUC3IYu+a2xEQbQiUdW nnTj7jcOhbaHRGUx4hWPpo+gTQBBHF5oZhGDvRa3QmDkadN8NyskuVfarWDW/6RP 8weR+CqcJxNrsf6wMxmCnU0z8qh5OfL+f7zzhXqLwHJjct7Dk9N929y7dlSP6o6V bxcP3Kv3hGBcM6o9AaMF48IlLbjav0yjPueOn5qDqzIdpg99EXLGPLtnpq5D5R9+ Vdl3gaifbCz19uraOhJruis03Razor7qAuTv1eaZXixSuZhFbV9l7flYFGVFOQVe AfIzyjasFTM158c8WLh4JYzJDhQjUi0v1IsoRMmrhUdJsYnVJvKMrUickvBd/qc= =F+ET -----END PGP SIGNATURE----- --lvRtR5tTvPXN9SqK8eAlXnSjcjT5mIaHC--