From 7a80b649606b621bbee04563584ec1af43ccdb6b Mon Sep 17 00:00:00 2001 From: Moriyoshi Koizumi Date: Sun, 4 May 2003 11:22:00 +0000 Subject: [PATCH] MFH(r-1.109): added missing sanity check --- ext/standard/datetime.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/ext/standard/datetime.c b/ext/standard/datetime.c index 71d8aeb353..1c14aa3699 100644 --- a/ext/standard/datetime.c +++ b/ext/standard/datetime.c @@ -319,7 +319,11 @@ php_date(INTERNAL_FUNCTION_PARAMETERS, int gm) #else tzone = timezone; #endif - tname[0] = tzname[0]; + if (tzname[0] != NULL) { + tname[0] = tzname[0]; + } else { + tname[0] = "???"; + } #endif } -- 2.50.1