Code

Refactor parse_date for approxidate functions
authorRamkumar Ramachandra <artagnon@gmail.com>
Thu, 3 Jun 2010 20:28:55 +0000 (22:28 +0200)
committerJunio C Hamano <gitster@pobox.com>
Mon, 7 Jun 2010 22:52:43 +0000 (15:52 -0700)
commitc5043cc18579854681aa51ddb6e744fe2db24f51
treed2119d4979b7ccd70f78409f32fc1b1d950c34d5
parent7c42e390a37a11b1f7a77f5f07c261a8f930663a
Refactor parse_date for approxidate functions

approxidate_relative and approxidate_careful both use parse_date to
dump the timestamp to a character buffer and parse it back into a long
unsigned using strtoul(). Avoid doing this by creating a new
parse_date_toffset method.

Noticed-by: Jonathan Nieder <jrnieder@gmail.com>
Signed-off-by: Ramkumar Ramachandra <artagnon@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
date.c