Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 11 Aug 2018 17:24:57 -0500
From:      Pedro Giffuni <pfg@FreeBSD.org>
To:        Jilles Tjoelker <jilles@FreeBSD.org>, svn-src-head@freebsd.org
Subject:   Re: svn commit: r337618 - head/usr.bin/printf
Message-ID:  <a3b38121-ca34-b53a-52c3-a20118643e0f@FreeBSD.org>
In-Reply-To: <201808111113.w7BBDYTM053399@repo.freebsd.org>
References:  <201808111113.w7BBDYTM053399@repo.freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help
Duh!


On 08/11/18 06:13, Jilles Tjoelker wrote:
> Author: jilles
> Date: Sat Aug 11 11:13:34 2018
> New Revision: 337618
> URL: https://svnweb.freebsd.org/changeset/base/337618
>
> Log:
>    printf: Fix \c in %b in printf builtin exiting the shell after r337458
>    
>    SVN r337458 erroneously partially reverted r265885.
>    
>    This is immediately visible when running the Kyua/ATF tests for
>    usr.bin/printf, which actually test sh's printf builtin.
>    
>    PR:		229641
>
> Modified:
>    head/usr.bin/printf/printf.c
>
> Modified: head/usr.bin/printf/printf.c
> ==============================================================================
> --- head/usr.bin/printf/printf.c	Sat Aug 11 11:05:22 2018	(r337617)
> +++ head/usr.bin/printf/printf.c	Sat Aug 11 11:13:34 2018	(r337618)
> @@ -388,7 +388,7 @@ printf_doformat(char *fmt, int *rval)
>   
>   		free(p);
>   		if (getout)
> -			exit(*rval);
> +			return (end_fmt);
>   		break;
>   	}
>   	case 'c': {
>
Thanks for fixing this!
I recall it's the second time I (inadvertently) commit this bug.
So great to have a corresponding test!

Pedro.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?a3b38121-ca34-b53a-52c3-a20118643e0f>