Re: [PATCH 2/3] tracing: Fix parse_synth_field() error handling

2020-09-30 Thread Tom Zanussi
Hi Axel, On Tue, 2020-09-29 at 14:56 -0700, Axel Rasmussen wrote: > On Tue, Sep 29, 2020 at 1:33 PM Tom Zanussi > wrote: > > > > synth_field_size() returns either the size or an error. However, > > the > > code assigns the return val to ssize_t which is unsigned, and then > > tests whether it's

Re: [PATCH 2/3] tracing: Fix parse_synth_field() error handling

2020-09-29 Thread Axel Rasmussen
On Tue, Sep 29, 2020 at 1:33 PM Tom Zanussi wrote: > > synth_field_size() returns either the size or an error. However, the > code assigns the return val to ssize_t which is unsigned, and then > tests whether it's less than 0, which it isn't so discards the error. I think the patch is correct, b

[PATCH 2/3] tracing: Fix parse_synth_field() error handling

2020-09-29 Thread Tom Zanussi
synth_field_size() returns either the size or an error. However, the code assigns the return val to ssize_t which is unsigned, and then tests whether it's less than 0, which it isn't so discards the error. Do the test before assignment to field->size. Signed-off-by: Tom Zanussi --- kernel/trac