find: make -size match GNU find

This commit is contained in:
Denis Vlasenko
2007-06-16 00:30:52 +00:00
parent b941129ccb
commit 53a0e97196
4 changed files with 54 additions and 19 deletions

View File

@@ -49,9 +49,8 @@ unsigned type xstrtou(_range_sfx)(const char *numstr, int base,
if (strcmp(suffixes->suffix, e) == 0) {
if (XSTR_UTYPE_MAX / suffixes->mult < r)
goto range; /* overflow! */
++e;
r *= suffixes->mult;
break;
goto chk_range;
}
++suffixes;
}
@@ -61,6 +60,7 @@ unsigned type xstrtou(_range_sfx)(const char *numstr, int base,
It would be easy enough to allow though if desired. */
if (*e)
goto inval;
chk_range:
/* Finally, check for range limits. */
if (r >= lower && r <= upper)
return r;