diff options
| author | Jilles Tjoelker <jilles@FreeBSD.org> | 2010-12-29 21:38:00 +0000 |
|---|---|---|
| committer | Jilles Tjoelker <jilles@FreeBSD.org> | 2010-12-29 21:38:00 +0000 |
| commit | add265c6ba450d4930722a277cd0bc8ac5b42b25 (patch) | |
| tree | 034d528fcbbbed78655f6952a94e69c9468e5dd2 /usr.bin/printf/printf.c | |
| parent | fef87167c971c16afa3807bdccdcdb46770a7b0e (diff) | |
Notes
Diffstat (limited to 'usr.bin/printf/printf.c')
| -rw-r--r-- | usr.bin/printf/printf.c | 13 |
1 files changed, 0 insertions, 13 deletions
diff --git a/usr.bin/printf/printf.c b/usr.bin/printf/printf.c index d2fd37e2cb2a..34bb0a2e6715 100644 --- a/usr.bin/printf/printf.c +++ b/usr.bin/printf/printf.c @@ -58,7 +58,6 @@ static const char rcsid[] = #ifdef SHELL #define main printfcmd #include "bltin/bltin.h" -#include "memalloc.h" #include "error.h" #endif @@ -256,11 +255,7 @@ printf_doformat(char *start, int *rval) char *p; int getout; -#ifdef SHELL - p = savestr(getstr()); -#else p = strdup(getstr()); -#endif if (p == NULL) { warnx("%s", strerror(ENOMEM)); return (NULL); @@ -269,11 +264,7 @@ printf_doformat(char *start, int *rval) *(fmt - 1) = 's'; PF(start, p); *(fmt - 1) = 'b'; -#ifdef SHELL - ckfree(p); -#else free(p); -#endif if (getout) return (fmt); break; @@ -342,11 +333,7 @@ mknum(char *str, char ch) len = strlen(str) + 2; if (len > copy_size) { newlen = ((len + 1023) >> 10) << 10; -#ifdef SHELL - if ((newcopy = ckrealloc(copy, newlen)) == NULL) -#else if ((newcopy = realloc(copy, newlen)) == NULL) -#endif { warnx("%s", strerror(ENOMEM)); return (NULL); |
