Re: [PATCH 4/4] cpukit/libmisc/dumpbuf/dumpbuf.c: Fix undefined behavior for sprintf().

2015-09-01 Thread Daniel Gutson
El 1/9/2015 23:10, "Joel Sherrill" escribió: > > > > On September 1, 2015 8:33:54 PM CDT, Daniel Gutson < daniel.gut...@tallertechnologies.com> wrote: > >Is there any reason to not declare these variables as unsigned (int)? > >IIUC strlen returns an unsigned integral. Sign-correctnesd doesn't hurt

Re: [PATCH 4/4] cpukit/libmisc/dumpbuf/dumpbuf.c: Fix undefined behavior for sprintf().

2015-09-01 Thread Joel Sherrill
On September 1, 2015 8:33:54 PM CDT, Daniel Gutson wrote: >Is there any reason to not declare these variables as unsigned (int)? >IIUC strlen returns an unsigned integral. Sign-correctnesd doesn't hurt >and I saw many bugs caused by the lack of it (the last one being pushed >few says ago in the

Re: [PATCH 4/4] cpukit/libmisc/dumpbuf/dumpbuf.c: Fix undefined behavior for sprintf().

2015-09-01 Thread Daniel Gutson
Is there any reason to not declare these variables as unsigned (int)? IIUC strlen returns an unsigned integral. Sign-correctnesd doesn't hurt and I saw many bugs caused by the lack of it (the last one being pushed few says ago in the Chromium beowser). El 1/9/2015 18:41, "Joel Sherrill" escribió:

[PATCH 4/4] cpukit/libmisc/dumpbuf/dumpbuf.c: Fix undefined behavior for sprintf().

2015-09-01 Thread Joel Sherrill
Updates #2405. --- cpukit/libmisc/dumpbuf/dumpbuf.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/cpukit/libmisc/dumpbuf/dumpbuf.c b/cpukit/libmisc/dumpbuf/dumpbuf.c index 9d34d42..36a8656 100644 --- a/cpukit/libmisc/dumpbuf/dumpbuf.c +++ b/cpukit/libmisc/dumpbuf/dumpbu