This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] gdb: Fix sizeof for dynamic types other than arrays


>>>>> "Andrew" == Andrew Burgess <andrew.burgess@embecosm.com> writes:

Andrew> All dynamic types are treated as arrays in the 'sizeof' code path,
Andrew> which means that structures can incorrectly be treated as arrays.
Andrew> This can cause a failure in the gdb.base/vla-datatypes.exp test
Andrew> script.

I noticed this with -fsanitize=address just yesterday as well.

Andrew> 	* eval.c (evaluate_subexp_for_sizeof): Check for array type before
Andrew> 	checking array bounds are defined.

This is ok.  Thank you.

Tom


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]