[PATCH] Guard a call to TYPE_TARGET_TYPE in gnuv3_pass_by_reference

Pedro Alves palves@redhat.com
Thu Oct 16 18:01:00 GMT 2014


Hi Siva,

On 10/16/2014 03:38 PM, Siva Chandra wrote:
> A call to TYPE_TARGET_TYPE was being done without checking if the type
> does have a target type. This was introduced by my commit:
> 82c48ac732edb0155288a93ef3dd39625ff2d2e1
> 
> The attached patch fixes it. This probably qualifies as an obvious
> fix, but just in case.
> 
>  2014-10-16  Siva Chandra Reddy  <sivachandra@google.com>
> 
>         * gnu-v3-abi.c (gnuv3_pass_by_reference): Call TYPE_TARGET_TYPE
>         on the arg type of a constructor only if it is of reference type.
> 

How did you notice this?  Does an existing test catch it?

Thanks,
Pedro Alves



More information about the Gdb-patches mailing list