From f3719d90a6ab4600dab4ab5e7f238b75105cca00 Mon Sep 17 00:00:00 2001 From: Alan Modra Date: Fri, 18 May 2012 23:21:49 +0000 Subject: * config/tc-dlx.c (s_proc): Don't use asprintf. --- gas/config/tc-dlx.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'gas/config/tc-dlx.c') diff --git a/gas/config/tc-dlx.c b/gas/config/tc-dlx.c index 530e03c..a629533 100644 --- a/gas/config/tc-dlx.c +++ b/gas/config/tc-dlx.c @@ -246,8 +246,10 @@ s_proc (int end_p) char prepended. */ if (leading_char) { - if (asprintf (&label, "%c%s", leading_char, name)) - { /* Avoid warning */ } + unsigned len = strlen (name) + 1; + label = xmalloc (len + 1); + label[0] = leading_char; + memcpy (label + 1, name, len); } else label = name; -- cgit v1.1