bug-coreutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#7574: [PATCH]: echo, printf, stat: Allow only up to 8 bit octal inpu


From: Paul Eggert
Subject: bug#7574: [PATCH]: echo, printf, stat: Allow only up to 8 bit octal input for backslash-escaped chars
Date: Mon, 06 Dec 2010 12:43:02 -0800
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1.15) Gecko/20101027 Thunderbird/3.0.10

As a minor point, both uses like this:

'4' <= *p && *p <= '7'

can be replaced with something like this:

'4' <= *p

and similarly, this:

'0' <= c && c <= '3'

can be replaced with this:

c < '4'

The replacements are not only shorter, but easier
to understand, because otherwise the reader is left
wondering why that unnecessary comparison to '7'
(or '0') is in there.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]