mirror of
https://github.com/php/php-src.git
synced 2024-09-22 10:27:25 +00:00
(PHP ifx_errormsg) Fixed Informix bug where ifx_errormsg() would Segfault
on an unopened connecection and with an errorcode supplied
This commit is contained in:
parent
a7132f74fd
commit
7afe50fc5c
@ -1650,6 +1650,7 @@ PHP_FUNCTION(ifx_errormsg)
|
||||
}
|
||||
|
||||
maxmsglen = 255;
|
||||
msglen = maxmsglen; // Some bug fix, rgetlmsg doesnt always set the value
|
||||
ifx_errmsg = (char *)malloc(maxmsglen + 1);
|
||||
if (ifx_errorcode != 0) {
|
||||
rgetlmsg(ifx_errorcode, ifx_errmsg, maxmsglen, &msglen);
|
||||
|
Loading…
Reference in New Issue
Block a user