[CONC-137] Error code not set in mysql_stmt_send_long_data Created: 2015-08-16 Updated: 2015-08-16 Resolved: 2015-08-16 |
|
| Status: | Closed |
| Project: | MariaDB Connector/C |
| Component/s: | None |
| Affects Version/s: | 2.1 |
| Fix Version/s: | 3.0.0, 2.2.0 |
| Type: | Bug | Priority: | Minor |
| Reporter: | Matt Fagan | Assignee: | Georg Richter |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Environment: |
All |
||
| Description |
|
If you call mysql_stmt_send_long_data while the MYSQL* is in the wrong state, it returns the fact that there is an error, but no error code. To correct, I think the conditional on line 1816 needs to be changed from: To: if (length || !stmt->params[param_number].long_data_used)) |
| Comments |
| Comment by Georg Richter [ 2015-08-16 ] | ||||||||||||||||||||
|
Hi Matt, thanks for your bug report. The extra check for status is redundant, since it will be checked in simple_command/mthd_my_send_cmd. To be compatible with libmysql we also should allow to pass a zero length buffer instead of returning an error.:
| ||||||||||||||||||||
| Comment by Georg Richter [ 2015-08-16 ] | ||||||||||||||||||||
|
fixed (changeset a6f40f2b97b35a15b75c3a419fcfe3a894628675) |