[tz] [PROPOSED] Commentary fixes
Paul Eggert
eggert at cs.ucla.edu
Mon Jun 12 18:23:53 UTC 2017
* Makefile: Mention constraints on TZDIR_BASENAME.
* asctime.c: Remove obsolete comment, as zdump now uses snprintf.
---
Makefile | 1 +
asctime.c | 3 ---
2 files changed, 1 insertion(+), 3 deletions(-)
diff --git a/Makefile b/Makefile
index 05b40bb..07f4f77 100644
--- a/Makefile
+++ b/Makefile
@@ -49,6 +49,7 @@ TOPDIR= /usr/local
# "Compiled" time zone information is placed in the "TZDIR" directory
# (and subdirectories).
# Use an absolute path name for TZDIR unless you're just testing the software.
+# TZDIR_BASENAME should not contain "/" and should not be ".", ".." or empty.
TZDIR_BASENAME= zoneinfo
TZDIR= $(TOPDIR)/etc/$(TZDIR_BASENAME)
diff --git a/asctime.c b/asctime.c
index 1613f78..de681ce 100644
--- a/asctime.c
+++ b/asctime.c
@@ -99,9 +99,6 @@ asctime_r(register const struct tm *timeptr, char *buf)
** (e.g., timeptr->tm_mday) when processing "%Y".
*/
strftime(year, sizeof year, "%Y", timeptr);
- /*
- ** We avoid using snprintf since it's not available on all systems.
- */
sprintf(result,
((strlen(year) <= 4) ? ASCTIME_FMT : ASCTIME_FMT_B),
wn, mn,
--
2.9.4
More information about the tz
mailing list