diff options
author | unknown <hf@deer.(none)> | 2004-08-19 15:36:05 +0500 |
---|---|---|
committer | unknown <hf@deer.(none)> | 2004-08-19 15:36:05 +0500 |
commit | 84779aef24cabafd26e8445fbe60c1d3a0c2b4e9 (patch) | |
tree | b98c20512095d00b35003e248dbcedc4350ac173 | |
parent | 205703ff06f4f90d3542fe593294c3c54b06a5ec (diff) | |
download | mariadb-git-84779aef24cabafd26e8445fbe60c1d3a0c2b4e9.tar.gz |
addition to fixes about #4700, 4701
libmysqld/lib_sql.cc:
Comment added
sql/sql_prepare.cc:
Necessary line added to emb_insert_params_with_log
-rw-r--r-- | libmysqld/lib_sql.cc | 6 | ||||
-rw-r--r-- | sql/sql_prepare.cc | 1 |
2 files changed, 7 insertions, 0 deletions
diff --git a/libmysqld/lib_sql.cc b/libmysqld/lib_sql.cc index 5ecea557361..51a723d225a 100644 --- a/libmysqld/lib_sql.cc +++ b/libmysqld/lib_sql.cc @@ -108,6 +108,12 @@ emb_advanced_command(MYSQL *mysql, enum enum_server_command command, if (!skip_check) result= thd->net.last_errno ? -1 : 0; + /* + If mysql->field_count is set it means the parsing of the query was OK + and metadata was returned (see Protocol::send_fields). + In this case we postpone the error to be returned in mysql_stmt_store_result + (see emb_read_rows) to behave just as standalone server. + */ if (!mysql->field_count) embedded_get_error(mysql); mysql->server_status= thd->server_status; diff --git a/sql/sql_prepare.cc b/sql/sql_prepare.cc index 47cc461fac0..754da84f257 100644 --- a/sql/sql_prepare.cc +++ b/sql/sql_prepare.cc @@ -737,6 +737,7 @@ static bool emb_insert_params_withlog(Prepared_statement *stmt, String *query) else { uchar *buff= (uchar*)client_param->buffer; + param->unsigned_flag= client_param->is_unsigned; param->set_param_func(param, &buff, client_param->length ? *client_param->length : |