about summary refs log tree commit diff
path: root/shadow
diff options
context:
space:
mode:
Diffstat (limited to 'shadow')
-rw-r--r--shadow/sgetspent_r.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/shadow/sgetspent_r.c b/shadow/sgetspent_r.c
index ba2e8186bc..8678ac816a 100644
--- a/shadow/sgetspent_r.c
+++ b/shadow/sgetspent_r.c
@@ -51,9 +51,12 @@ LINE_PARSER
  else
    {
      STRING_FIELD (result->sp_pwdp, ISCOLON, 0);
-     INT_FIELD (result->sp_lstchg, ISCOLON, 0, 10, (long int));
-     INT_FIELD (result->sp_min, ISCOLON, 0, 10, (long int));
-     INT_FIELD (result->sp_max, ISCOLON, 0, 10, (long int));
+     INT_FIELD_MAYBE_NULL (result->sp_lstchg, ISCOLON, 0, 10, (long int),
+			   (long int) -1);
+     INT_FIELD_MAYBE_NULL (result->sp_min, ISCOLON, 0, 10, (long int),
+			   (long int) -1);
+     INT_FIELD_MAYBE_NULL (result->sp_max, ISCOLON, 0, 10, (long int),
+			   (long int -1);
      while (isspace (*line))
        ++line;
      if (*line == '\0')