The values are retrieved from login.defs files, which normally do not
contain negative values. In fact, negative value -1 is used in many
code places as "feature disabled", which is normally achieved by
simply commenting out the key from the file.
Signed-off-by: Tobias Stoeckmann <tobias@stoeckmann.org>
if ( (getlong (d->value, &val) == 0)
|| (val > INT_MAX)
- || (val < INT_MIN)) {
+ || (val < -1)) {
fprintf (shadow_logfd,
_("configuration error - cannot parse %s value: '%s'"),
item, d->value);
return dflt;
}
- if (getlong (d->value, &val) == 0) {
+ if ( (getlong (d->value, &val) == 0)
+ || (val < -1)) {
fprintf (shadow_logfd,
_("configuration error - cannot parse %s value: '%s'"),
item, d->value);