Bug#261570: Missed XSI:isms...

Robert Millan Robert Millan <zeratul2@wanadoo.es>, 261570@bugs.debian.org
Mon, 26 Jul 2004 21:59:28 +0200


On Mon, Jul 26, 2004 at 09:12:19PM +0200, David Weinehall wrote:
> 
> Doh.  I seem to have missed out a `local' in debian/update-grub and
> a couple of `-a' in util/mkbimage.  The included patch fixes this.

> diff -ur grub-0.95+cvs20040624-old/debian/update-grub grub-0.95+cvs20040624/debian/update-grub
> --- grub-0.95+cvs20040624-old/debian/update-grub	2004-07-25 18:14:29.000000000 +0300
> +++ grub-0.95+cvs20040624/debian/update-grub	2004-07-26 21:55:32.000000000 +0300
> @@ -201,7 +201,6 @@
>  # Calls OS-specific convert, and returns a default of
>  # (hd0,0) if anything goes wrong
>  convert_default () {
> -	local tmp
>  	if tmp=$(convert $1 2>/dev/null) ; then
>  		echo $tmp
>  	else

What does 'local' do? How is it that removing it is harmless?

> diff -ur grub-0.95+cvs20040624-old/util/mkbimage grub-0.95+cvs20040624/util/mkbimage
> --- grub-0.95+cvs20040624-old/util/mkbimage	2004-04-29 22:45:11.000000000 +0300
> +++ grub-0.95+cvs20040624/util/mkbimage	2004-07-26 21:57:09.000000000 +0300
> @@ -232,10 +232,10 @@
>  
>  if [ ! "$image_type" ]; then
>  	image_type=hd;
> -elif [ "$image_type" != "1.20" -a "$image_type" != "1.44" \
> -  -a "$image_type" != "1.60" -a "$image_type" != "1.68" \
> -  -a "$image_type" != "2.88" -a "$image_type" != "1.74" \
> -  -a "$image_type" != "hd" -a "$image_type" != "1.60" ] ; then
> +elif [ "$image_type" != "1.20" ] && [ "$image_type" != "1.44" ] && \
> +     [ "$image_type" != "1.60" ] && [ "$image_type" != "1.68" ] && \
> +     [ "$image_type" != "2.88" ] && [ "$image_type" != "1.74" ] && \
> +     [ "$image_type" != "hd" ] && [ "$image_type" != "1.60" ] ; then
>    error wrong_type ;
>  fi

This part was already in the package (in debian/patches/). I did also commit
it in upstream.

-- 
Robert Millan

(Debra and Ian) (Gnu's Not (UNiplexed Information and Computing System))/\
(kernel of *(Berkeley Software Distribution))