- ER() macro now checks if the error code is known, if not it will return
"Unknown or undefined error code" (instead of crashing)
- SET_CLIENT_STMT_ERROR now maps to stmt_set_error and accepts variadic
arguments
- removed unused methods from MYSQL_STMT handle,
(left over from PHP's mysqlnd)
- Added execute_generate_request method: This will allow
Connector/Python to prefill the execute buffer without
numerous GIL acquire/release calls.
If strncpy() truncates the string due to insufficient destination
buffer, it will not NUL-terminate the destination string.
9faaea38bc ensured that the
destination string will always be NUL-terminated, by writing a NUL to
the end of the buffer.
But, it failed to silence a -Wstringop-truncation warning.
This fix (which should be non-functional) actually does that.
Client application can now register callback functions for either sending or retrieving data:
- typedef void (*ps_result_callback)(MYSQL_STMT *stmt, unsigned int column, unsigned char **row);
- typedef my_bool *(*ps_param_callback)(MYSQL_STMT *stmt, MYSQL_BIND *bind, unsigned int row_nr);
These functions will be registerd via mysql_stmt_attr_set call by specifying options STMT_ATTR_CB_PARAM
or STMT_ATTR_CB_RESULT.
The revision also adds some (mainly VS specific) file/dirs definitions to .gitignore to make 'gid status' usable on Windows, and the typo in bulk1 testsuite
After test fixes.
bulk_null() is disabled. Before the client library took care about MYSQL_TYPE_NULL, now it do not do it so server return an error. and I have no idea what should be chenged test or client library.
- allow param binding via mysql_stmt_attr_set:
mysql_stmt_attr_set(stmt, STMT_ATTR_PREBIND_PARAMS, ¶m_count);
- If a prepared statement will be reexecuted, we send COM_STMT_CLOSE
together with COM_STMT_PREPARE and COM_STMT_EXECUTE