Skip to content

Commit 9fc3818

Browse files
committed
Fixed segfault in mysqlnd when doing long prepare
1 parent b34e8d2 commit 9fc3818

File tree

3 files changed

+54
-0
lines changed

3 files changed

+54
-0
lines changed

NEWS

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,9 @@ PHP NEWS
2121

2222
- Intl:
2323
. Fixed bug #62759: Buggy grapheme_substr() on edge case. (Stas)
24+
25+
- mysqlnd:
26+
. Fixed segfault in mysqlnd when doing long prepare. (Andrey)
2427

2528
- ODBC:
2629
. Fixed bug #61387 (NULL valued anonymous column causes segfault in

ext/mysqli/tests/mysqli_stmt_big_prepare.phpt

Lines changed: 50 additions & 0 deletions
Large diffs are not rendered by default.

ext/mysqlnd/mysqlnd_ps_codec.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -626,6 +626,7 @@ mysqlnd_stmt_execute_store_params(MYSQLND_STMT * s, zend_uchar **buf, zend_uchar
626626
*p += null_count;
627627
}
628628

629+
left = (*buf_len - (*p - *buf));
629630
/* 1. Store type information */
630631
/*
631632
check if need to send the types even if stmt->send_types_to_server is 0. This is because

0 commit comments

Comments
 (0)