all repos — cgit @ 17c74eefa4390d42a244b12885dc63ac4a764e44

a hyperfast web frontend for git written in c

ui-shared: remove cgit_print_date()

There are no longer any users of this function.

Signed-off-by: John Keeping <john@keeping.me.uk>
John Keeping john@keeping.me.uk
Tue, 19 Jan 2016 19:33:08 +0000
commit

17c74eefa4390d42a244b12885dc63ac4a764e44

parent

eb80b4edadd07957f667f057c82875c30a822a1f

2 files changed, 0 insertions(+), 21 deletions(-)

jump to
M ui-shared.cui-shared.c

@@ -607,26 +607,6 @@ if (item && tail)

path[len - 1] = tail; } -static const char *fmt_date(time_t secs, const char *format, int local_time) -{ - static char buf[64]; - struct tm *time; - - if (!secs) - return ""; - if (local_time) - time = localtime(&secs); - else - time = gmtime(&secs); - strftime(buf, sizeof(buf)-1, format, time); - return buf; -} - -void cgit_print_date(time_t secs, const char *format, int local_time) -{ - html_txt(fmt_date(secs, format, local_time)); -} - const struct date_mode *cgit_date_mode(const char *format) { static struct date_mode mode;
M ui-shared.hui-shared.h

@@ -62,7 +62,6 @@ extern void cgit_print_error(const char *fmt, ...);

__attribute__((format (printf,1,0))) extern void cgit_vprint_error(const char *fmt, va_list ap); extern const struct date_mode *cgit_date_mode(const char *format); -extern void cgit_print_date(time_t secs, const char *format, int local_time); extern void cgit_print_age(time_t t, int tz, time_t max_relative); extern void cgit_print_http_headers(void); extern void cgit_redirect(const char *url, bool permanent);