Arithmetic comparisons to be same way around

In writing arithmetic comparisons, use "<" and "<=" rather than
">" and ">=". For some justification, read this:

http://thread.gmane.org/gmane.comp.version-control.git/3903/focus=4126

Signed-off-by: Sami Kerola <kerolasa@iki.fi>
This commit is contained in:
Sami Kerola 2011-01-22 12:35:18 +01:00
parent e6c32dbdf9
commit ee35f8bb1f
5 changed files with 37 additions and 36 deletions

View file

@ -140,7 +140,7 @@ int main(int argc, char **argv)
/* Output sorting option */
if (optarg != NULL) {
sorts = strlen(optarg);
if (sorts > 5) {
if (5 < sorts) {
eprintf
("main: only 5 first sort orders will be used");
strncpy(config.sort, optarg,