diff options
| author | Pedro F. Giffuni <pfg@FreeBSD.org> | 2018-08-08 15:12:32 +0000 |
|---|---|---|
| committer | Pedro F. Giffuni <pfg@FreeBSD.org> | 2018-08-08 15:12:32 +0000 |
| commit | 94e460157dfd5f00a7e2eefce10137d3a5f8dd6e (patch) | |
| tree | 4efc842098c277d9f9119c3352396d879e5ac9cd /usr.bin | |
| parent | c820acbf0a7df4794b39c1e12b55e96a12f70cba (diff) | |
Notes
Diffstat (limited to 'usr.bin')
| -rw-r--r-- | usr.bin/printf/printf.c | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/usr.bin/printf/printf.c b/usr.bin/printf/printf.c index 024c3f0df0be..8482bb391b87 100644 --- a/usr.bin/printf/printf.c +++ b/usr.bin/printf/printf.c @@ -1,7 +1,6 @@ /*- * SPDX-License-Identifier: BSD-3-Clause * - * Copyright 2018 Staysail Systems, Inc. <info@staysail.tech> * Copyright 2014 Garrett D'Amore <garrett@damore.org> * Copyright 2010 Nexenta Systems, Inc. All rights reserved. * Copyright (c) 1989, 1993 @@ -376,19 +375,16 @@ printf_doformat(char *fmt, int *rval) char *p; int getout; - /* Convert "b" to "s" for output. */ - start[strlen(start) - 1] = 's'; - if ((p = strdup(getstr())) == NULL) { + p = strdup(getstr()); + if (p == NULL) { warnx("%s", strerror(ENOMEM)); return (NULL); } getout = escape(p, 0, &len); - PF(start, p); - /* Restore format for next loop. */ - + fputs(p, stdout); free(p); if (getout) - exit(*rval); + return (end_fmt); break; } case 'c': { |
