[RFC/PATCH 0/2] Commits with ancient timestamps

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Result of conversion of ancient history from other SCMs, and output from
other third-party tools, can record timestamps that predates inception of
Git. They can cause "git am", "git rebase" and "git commit --amend" to
misbehave, because the raw git timestamp e.g.

	author <a.u.thor@xxxxxxxxxxx> 1328214896 -0800

are read from the commit object and passed to parse_date() machinery,
which rejects raw git timestamps without sufficient number of digits to
avoid misinterpreting human-written timestamp in other formats, and
timestamps before 1975 do not have enough number of digits in them.

Here is a two-patch series that may improve the situation.

Note that this is not meant for direct application, unless somebody uses
this extensively to make sure there is no regression.


Junio C Hamano (2):
  parse_date(): allow ancient timestamps in in-header format
  parse_date(): '@' prefix forces git-timestamp interpretation

 date.c          |   30 ++++++++++++++++++++++++++++++
 git-sh-setup.sh |    2 +-
 2 files changed, 31 insertions(+), 1 deletions(-)

-- 
1.7.9.172.ge26ae

--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]