Skip to content

Commit 46a6842

Browse files
committed
fsck: allow negative sign in timestamp
Later changes may also touch parse_timestamp_from_buf(), which does not yet exist. It would need to be tweaked, too.
1 parent 4fdee76 commit 46a6842

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

fsck.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -928,7 +928,7 @@ static int fsck_ident(const char **ident, const char *ident_end,
928928
*/
929929
while (*p == ' ' || *p == '\t')
930930
p++;
931-
if (!isdigit(*p))
931+
if (!isdigit(*p) && *p != '-')
932932
return report(options, oid, type, FSCK_MSG_BAD_DATE,
933933
"invalid author/committer line - bad date");
934934
if (*p == '0' && p[1] != ' ')

0 commit comments

Comments
 (0)