Re: [PATCH] gcc/ubsan.c: Extend 'pretty_name' space to avoid memory overflow

2014-11-20 Thread Chen Gang
On 11/17/14 18:52, Chen Gang wrote: > > What you said sound reasonable to me. > > I shall try to send patch v2 within this week (use pretty_printer). > > Thanks. > > On 11/17/14 16:15, Marek Polacek wrote: >> On Mon, Nov 17, 2014 at 08:38:19AM +0100, Jakub Jelinek wrote: >> >>> I think easiest

Re: [PATCH] gcc/ubsan.c: Extend 'pretty_name' space to avoid memory overflow

2014-11-17 Thread Chen Gang
What you said sound reasonable to me. I shall try to send patch v2 within this week (use pretty_printer). Thanks. On 11/17/14 16:15, Marek Polacek wrote: > On Mon, Nov 17, 2014 at 08:38:19AM +0100, Jakub Jelinek wrote: >> On Mon, Nov 17, 2014 at 08:16:32AM +0100, Marek Polacek wrote: >>> On Mon

Re: [PATCH] gcc/ubsan.c: Extend 'pretty_name' space to avoid memory overflow

2014-11-17 Thread Marek Polacek
On Mon, Nov 17, 2014 at 08:38:19AM +0100, Jakub Jelinek wrote: > On Mon, Nov 17, 2014 at 08:16:32AM +0100, Marek Polacek wrote: > > On Mon, Nov 17, 2014 at 06:40:26AM +0800, Chen Gang wrote: > > > According to the next code, 'pretty_name' may need additional bytes more > > > than 16. For simplify t

Re: [PATCH] gcc/ubsan.c: Extend 'pretty_name' space to avoid memory overflow

2014-11-16 Thread Jakub Jelinek
On Mon, Nov 17, 2014 at 08:16:32AM +0100, Marek Polacek wrote: > On Mon, Nov 17, 2014 at 06:40:26AM +0800, Chen Gang wrote: > > According to the next code, 'pretty_name' may need additional bytes more > > than 16. For simplify thinking and being extensible in future, extent it > > to 256 bytes, dir

Re: [PATCH] gcc/ubsan.c: Extend 'pretty_name' space to avoid memory overflow

2014-11-16 Thread Marek Polacek
On Mon, Nov 17, 2014 at 06:40:26AM +0800, Chen Gang wrote: > According to the next code, 'pretty_name' may need additional bytes more > than 16. For simplify thinking and being extensible in future, extent it > to 256 bytes, directly. I think + 128 bytes should be enough for everyone. Mar

[PATCH] gcc/ubsan.c: Extend 'pretty_name' space to avoid memory overflow

2014-11-16 Thread Chen Gang
According to the next code, 'pretty_name' may need additional bytes more than 16. For simplify thinking and being extensible in future, extent it to 256 bytes, directly. It passes testsuite under fedora 20 x86_64-unknown-linux-gnu. 2014-11-17 Chen Gang * ubsan.c (ubsan_type_descripto