Skip to content

Commit 3b74a3e

Browse files
kamil-tekielaju1ius
authored andcommitted
Fix error checking in mysqlnd
Closes phpGH-11925
1 parent 7d9cf5b commit 3b74a3e

File tree

2 files changed

+29
-2
lines changed

2 files changed

+29
-2
lines changed

NEWS

Lines changed: 28 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,34 @@ PHP NEWS
1414
are passed in. (Derick)
1515

1616
- DOM:
17-
. adoptNode now respects the strict error checking property. (nielsdos)
18-
. Align DOMChildNode parent checks with spec. (nielsdos)
17+
. Fix DOMEntity field getter bugs. (nielsdos)
18+
. Fix incorrect attribute existence check in DOMElement::setAttributeNodeNS.
19+
(nielsdos)
20+
. Fix DOMCharacterData::replaceWith() with itself. (nielsdos)
21+
. Fix empty argument cases for DOMParentNode methods. (nielsdos)
22+
. Fixed bug GH-11791 (Wrong default value of DOMDocument::xmlStandalone).
23+
(nielsdos)
24+
. Fix json_encode result on DOMDocument. (nielsdos)
25+
. Fix manually calling __construct() on DOM classes. (nielsdos)
26+
. Fixed bug GH-11830 (ParentNode methods should perform their checks
27+
upfront). (nielsdos)
28+
. Fix segfault when DOMParentNode::prepend() is called when the child
29+
disappears. (nielsdos)
30+
31+
- FFI:
32+
. Fix leaking definitions when using FFI::cdef()->new(...). (ilutov)
33+
34+
- MySQLnd:
35+
. Fixed bug GH-11440 (authentication to a sha256_password account fails over
36+
SSL). (nielsdos)
37+
. Fixed bug GH-11438 (mysqlnd fails to authenticate with sha256_password
38+
accounts using passwords longer than 19 characters).
39+
(nielsdos, Kamil Tekiela)
40+
. Fixed bug GH-11550 (MySQL Statement has a empty query result when
41+
the response field has changed, also Segmentation fault).
42+
(Yurunsoft)
43+
. Fixed invalid error message "Malformed packet" when connection is dropped.
44+
(Kamil Tekiela)
1945

2046
- Opcache:
2147
. Avoid resetting JIT counter handlers from multiple processes/threads.

ext/mysqlnd/mysqlnd_protocol_frame_codec.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -202,6 +202,7 @@ MYSQLND_METHOD(mysqlnd_pfc, send)(MYSQLND_PFC * const pfc, MYSQLND_VIO * const v
202202
if (bytes_sent <= 0) {
203203
DBG_ERR_FMT("Can't %zu send bytes", count);
204204
SET_CLIENT_ERROR(error_info, CR_SERVER_GONE_ERROR, UNKNOWN_SQLSTATE, mysqlnd_server_gone);
205+
bytes_sent = 0; // the return type is unsigned and 0 represents an error condition
205206
}
206207
DBG_RETURN(bytes_sent);
207208
}

0 commit comments

Comments
 (0)