On Thu, Apr 26, 2012 at 5:34 AM, Dodji Seketeli <do...@seketeli.org> wrote:
> Hello all, and sorry for getting into this a bit late.  I have a
> question concerning this patch:
>
>> +++ cp/call.c (working copy)
>
> [...]
>
>> +static const char *
>> +op_error_string (const char *err_msg, int ntypes, bool match)
>> +{
>> +  const char *msg;
>> +
>> +  const char *msgt = concat (match ? G_("ambiguous overload for ")
>> +                                : G_("no match for "), err_msg, NULL);
>> +
>> +  if (ntypes == 3)
>> +    msg = concat (msgt, G_(" (operand types are %qT, %qT, and %qT)"), NULL);
>> +  else if (ntypes == 2)
>> +    msg = concat (msgt, G_(" (operand types are %qT and %qT)"), NULL);
>> +  else
>> +    msg = concat (msgt, G_(" (operand type is %qT)"), NULL);
>> +
>> +  return msg;
>> +}
>> +
>
> I am wondering if the last uses of concat here (without freeing the
> previous msgt) lead to a memory leak or not ...
>
> Sorry for the noise if I just misunderstood things here.

yes, it does.  On the other hand, the program is going to exit soon...

-- Gaby

Reply via email to