Subject: Re: [PATCH iproute2 1/2] utils: add s32 parser

From: Hagen Paul Pfeifer <[email-masked]>
Date: Fri, 25 Nov 2011 18:47:51 +0100

* David Laight | 2011-11-25 17:34:21 [-0000]:

>If you are that worried about numeric overflow (IIRC) you have
>have to check the result for LONG_MIN/MAX (etc) before looking
>at errno.
>
>strtoul() is defined to support -ve values, and I think the
>C rules for conversion between signed and unsigned ints
>DTRT even for non 2's compliment systems.
>
>Some of these bound checks are a waste of time.
>The SUS doesn't require standard utilities to perform them.

David: are you able to fix all conversations functions in utils.c (and add
get_s32). If not I will repost get_s32 with strtol() with the same error check
mechanism as get_* (to be consistent).

Stephen, any other ideas?

Hagen