Skip to content

Commit

Permalink
src/faillog.c: Simplify, by calling str2sh() instead of str2sl()
Browse files Browse the repository at this point in the history
Reviewed-by: "Serge E. Hallyn" <[email protected]>
Signed-off-by: Alejandro Colomar <[email protected]>
  • Loading branch information
alejandro-colomar committed Jul 2, 2024
1 parent 0464c1a commit ab9f4da
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions src/faillog.c
Original file line number Diff line number Diff line change
Expand Up @@ -557,16 +557,12 @@ int main (int argc, char **argv)
break;
case 'm':
{
long lmax;

if ( (str2sl(&lmax, optarg) == -1)
|| ((long)(short) lmax != lmax)) {
if (str2sh(&fail_max, optarg) == -1) {
fprintf (stderr,
_("%s: invalid numeric argument '%s'\n"),
Prog, optarg);
exit (E_BAD_ARG);
}
fail_max = lmax;
mflg = true;
break;
}
Expand Down

0 comments on commit ab9f4da

Please sign in to comment.