diff options
Diffstat (limited to 'text-utils/hexdump-parse.c')
-rw-r--r-- | text-utils/hexdump-parse.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/text-utils/hexdump-parse.c b/text-utils/hexdump-parse.c index 272bb24..23fffc8 100644 --- a/text-utils/hexdump-parse.c +++ b/text-utils/hexdump-parse.c @@ -427,9 +427,7 @@ isint: cs[3] = '\0'; */ savech = *p2; p1[0] = '\0'; - pr->fmt = xmalloc(strlen(fmtp) + strlen(cs) + 1); - strcpy(pr->fmt, fmtp); - strcat(pr->fmt, cs); + xasprintf(&pr->fmt, "%s%s", fmtp, cs); *p2 = savech; pr->cchar = pr->fmt + (p1 - fmtp); fmtp = p2; |