From f1696d4f5f001d59204f19b2ef3fa921c9336a0f Mon Sep 17 00:00:00 2001 From: unknown Date: Thu, 26 Dec 2002 18:26:37 +0200 Subject: Cut hostnames at HOSTNAME_LENGTH to avoid theoretical hostname overruns Changed long packat handling to check for packets of length 0xffffff. This does however break packet handling for older clients. If you are using packets >= 16M then you need to upgrade client and server after this patch. Docs/internals.texi: Updated documentation for 4.1 protocol sql/ha_innodb.cc: Optimization of checking command sql/item.h: Removed automatic set of length for Item_string sql/item_create.cc: Optimized create of create_func_current_user() sql/net_serv.cc: Fixed wrong max packet length sql/sql_acl.cc: Safety fix. sql/sql_parse.cc: Cut hostnames at HOSTNAME_LENGTH to avoid theoretical hostname overruns --- sql/sql_acl.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'sql/sql_acl.cc') diff --git a/sql/sql_acl.cc b/sql/sql_acl.cc index 673bc441b6b..1f8f25e5fb8 100644 --- a/sql/sql_acl.cc +++ b/sql/sql_acl.cc @@ -1870,7 +1870,7 @@ static int replace_table_table(THD *thd, GRANT_TABLE *grant_table, ulong rights, ulong col_rights, bool revoke_grant) { - char grantor[HOSTNAME_LENGTH+1+USERNAME_LENGTH]; + char grantor[HOSTNAME_LENGTH+USERNAME_LENGTH+2]; int old_row_exists = 1; int error=0; ulong store_table_rights, store_col_rights; -- cgit v1.2.1