summaryrefslogtreecommitdiff
path: root/sql/net_serv.cc
diff options
context:
space:
mode:
authorunknown <konstantin@mysql.com>2004-09-08 23:07:11 +0400
committerunknown <konstantin@mysql.com>2004-09-08 23:07:11 +0400
commitd7a230677c90831d1f21426a56fd2d0a9106f31e (patch)
tree76941d331b5f9f18f220d5601314919a2df7ae04 /sql/net_serv.cc
parenta2e570ab39868a2b128e5dd3f3899ff960832a1b (diff)
downloadmariadb-git-d7a230677c90831d1f21426a56fd2d0a9106f31e.tar.gz
A fix and test case for Bug#5194 "Bulk Insert Failures with Prepared
Statements": - fix a couple of net->buff overruns in libmysql, - check in the server that statement parameter count is less than 65535 (maximum value supported by prepared statements protocol). libmysql/libmysql.c: Bug#5194 "Bulk Insert Failures with Prepared Statements": - clean up my_realloc_str() - ensure that net buffer has space when storing null bits and parameter typecodes. sql/net_serv.cc: - set net->last_errno if packet is too big, even on client (Why was it ifdefed before?) sql/sql_prepare.cc: Bug#5194 "Bulk Insert Failures with Prepared Statements": - if placeholder count is bigger than 65535, give error. We have only 2 bytes reserved for transferring placeholder count in 4.1 protocol. - can't add a proper error code and message in 4.1 because of possible merge difficulties." tests/client_test.c: A test case for Bug#5194 "Bulk Insert Failures with Prepared Statements".
Diffstat (limited to 'sql/net_serv.cc')
-rw-r--r--sql/net_serv.cc2
1 files changed, 0 insertions, 2 deletions
diff --git a/sql/net_serv.cc b/sql/net_serv.cc
index c2da47b480e..457b2052a45 100644
--- a/sql/net_serv.cc
+++ b/sql/net_serv.cc
@@ -193,9 +193,7 @@ my_bool net_realloc(NET *net, ulong length)
{
net->error= 1;
net->report_error= 1;
-#ifdef MYSQL_SERVER
net->last_errno= ER_OUT_OF_RESOURCES;
-#endif
DBUG_RETURN(1);
}
net->buff=net->write_pos=buff;