Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 11 Aug 2018 11:13:34 +0000 (UTC)
From:      Jilles Tjoelker <jilles@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r337618 - head/usr.bin/printf
Message-ID:  <201808111113.w7BBDYTM053399@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
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': {



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201808111113.w7BBDYTM053399>