Skip to content

Commit bcb39d9

Browse files
committed
Fixed typo ensuring header str is \0 terminated
This was obviously intended to send an empty header if php_gmtime_r() fails. Currently it could send garbage.
1 parent 9561e59 commit bcb39d9

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

ext/session/session.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1052,7 +1052,7 @@ static inline void strcpy_gmt(char *ubuf, time_t *when) /* {{{ */
10521052
res = php_gmtime_r(when, &tm);
10531053

10541054
if (!res) {
1055-
buf[0] = '\0';
1055+
ubuf[0] = '\0';
10561056
return;
10571057
}
10581058

0 commit comments

Comments
 (0)