Skip to content

Commit ba27866

Browse files
committed
Fix bug 76618
Apply patch which was attached to the bug in July 2018
1 parent 20cbb23 commit ba27866

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

NEWS

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ PHP NEWS
77
fulfilled by traits). (Nikita)
88

99
- IMAP:
10+
. Fixed bug #76618 (segfault on imap_reopen). (girgias)
1011
. Fixed bug #80239 (imap_rfc822_write_address() leaks memory). (cmb)
1112
. Fixed minor regression caused by fixing bug #80220. (cmb)
1213
. Fixed bug #80242 (imap_mail_compose() segfaults for multipart with rfc822).

ext/imap/php_imap.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -867,7 +867,7 @@ PHP_FUNCTION(imap_reopen)
867867

868868
imap_le_struct->imap_stream = mail_open(imap_le_struct->imap_stream, ZSTR_VAL(mailbox), flags);
869869
if (imap_le_struct->imap_stream == NIL) {
870-
zend_list_delete(Z_RES_P(streamind));
870+
zend_list_close(Z_RES_P(streamind));
871871
php_error_docref(NULL, E_WARNING, "Couldn't re-open stream");
872872
RETURN_FALSE;
873873
}

0 commit comments

Comments
 (0)