diff options
Diffstat (limited to 'date.c')
-rw-r--r-- | date.c | 19 |
1 files changed, 4 insertions, 15 deletions
@@ -4,8 +4,11 @@ * Copyright (C) Linus Torvalds, 2005 */ -#include "cache.h" +#include "git-compat-util.h" #include "date.h" +#include "gettext.h" +#include "pager.h" +#include "strbuf.h" /* * This is like mktime, but without normalization of tm_wday and tm_yday. @@ -1365,20 +1368,6 @@ static timestamp_t approxidate_str(const char *date, return (timestamp_t)update_tm(&tm, &now, 0); } -timestamp_t approxidate_relative(const char *date) -{ - struct timeval tv; - timestamp_t timestamp; - int offset; - int errors = 0; - - if (!parse_date_basic(date, ×tamp, &offset)) - return timestamp; - - get_time(&tv); - return approxidate_str(date, (const struct timeval *) &tv, &errors); -} - timestamp_t approxidate_careful(const char *date, int *error_ret) { struct timeval tv; |