@@ -795,8 +795,8 @@ static zend_string *date_format(char *format, size_t format_len, timelib_time *t
795
795
offset -> offset = (t -> z );
796
796
offset -> leap_secs = 0 ;
797
797
offset -> is_dst = 0 ;
798
- offset -> abbr = timelib_malloc (9 ); /* GMT±xxxx\0 */
799
- snprintf (offset -> abbr , 9 , "GMT%c%02d%02d" ,
798
+ offset -> abbr = timelib_malloc (13 ); /* GMT±xxxx\0 */
799
+ snprintf (offset -> abbr , 13 , "GMT%c%02d%02d" ,
800
800
(offset -> offset < 0 ) ? '-' : '+' ,
801
801
abs (offset -> offset / 3600 ),
802
802
abs ((offset -> offset % 3600 ) / 60 ));
@@ -1007,8 +1007,8 @@ PHPAPI int php_idate(char format, time_t ts, int localtime)
1007
1007
offset -> offset = (t -> z + (t -> dst * 3600 ));
1008
1008
offset -> leap_secs = 0 ;
1009
1009
offset -> is_dst = t -> dst ;
1010
- offset -> abbr = timelib_malloc (9 ); /* GMT±xxxx\0 */
1011
- snprintf (offset -> abbr , 9 , "GMT%c%02d%02d" ,
1010
+ offset -> abbr = timelib_malloc (13 ); /* GMT±xxxx\0 */
1011
+ snprintf (offset -> abbr , 13 , "GMT%c%02d%02d" ,
1012
1012
(offset -> offset < 0 ) ? '-' : '+' ,
1013
1013
abs (offset -> offset / 3600 ),
1014
1014
abs ((offset -> offset % 3600 ) / 60 ));
0 commit comments