summaryrefslogtreecommitdiff
path: root/src/utils.c
diff options
context:
space:
mode:
authorLukas Fleischer <calcurse@cryptocrack.de>2011-03-04 10:08:02 +0100
committerLukas Fleischer <calcurse@cryptocrack.de>2011-03-04 10:08:02 +0100
commitfdcfd74823beace1efbb01202e63e033755a8308 (patch)
tree9fdc1e53de06e0e4cd90b1a0e5f424e3655787e9 /src/utils.c
parent082e7d4b98b54eb3669b86d8cd236bad3a8ddbab (diff)
downloadcalcurse-fdcfd74823beace1efbb01202e63e033755a8308.zip
Remove date_sec2hour_str() from "utils.c".
date_sec2hour_str() is superseded by date_sec2date_str() with "%H:%M" as date format string, so replace all invocations and remove that function from "utils.c". Signed-off-by: Lukas Fleischer <calcurse@cryptocrack.de>
Diffstat (limited to 'src/utils.c')
-rw-r--r--src/utils.c16
1 files changed, 0 insertions, 16 deletions
diff --git a/src/utils.c b/src/utils.c
index 8988c53..ede1303 100644
--- a/src/utils.c
+++ b/src/utils.c
@@ -502,22 +502,6 @@ date2sec (struct date day, unsigned hour, unsigned min)
return t;
}
-/* Return a string containing the hour of a given date in seconds. */
-char *
-date_sec2hour_str (long sec)
-{
- const int TIME_LEN = 6;
- struct tm *lt;
- time_t t;
- char *timestr;
-
- t = sec;
- lt = localtime (&t);
- timestr = (char *) mem_malloc (TIME_LEN);
- (void)snprintf (timestr, TIME_LEN, "%02u:%02u", lt->tm_hour, lt->tm_min);
- return timestr;
-}
-
/* Return a string containing the date, given a date in seconds. */
char *
date_sec2date_str (long sec, char *datefmt)