From 3f97496772770b51f60a82843f1197b8618ffbd5 Mon Sep 17 00:00:00 2001 From: Willem Toorop Date: Wed, 11 Jan 2012 12:54:10 +0000 Subject: [PATCH] A trailing null is not necesarry when using strftime. I'm using to many scripting languages... --- rr_functions.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rr_functions.c b/rr_functions.c index be8f6868..b4847d62 100644 --- a/rr_functions.c +++ b/rr_functions.c @@ -363,7 +363,7 @@ uint32_t ldns_soa_serial_datecounter(uint32_t s, void *data) uint32_t new_s; time_t t = data ? (time_t) (intptr_t) data : ldns_time(NULL); - (void) strftime(s_str, 11, "%Y%m%d00\000", localtime_r(&t, &tm)); + (void) strftime(s_str, 11, "%Y%m%d00", localtime_r(&t, &tm)); new_s = (uint32_t) atoi(s_str); return new_s > s ? new_s : s+1; } -- 2.47.3