mirror of
https://github.com/MariaDB/server.git
synced 2026-05-10 00:54:30 +02:00
Merge with 4.1
BitKeeper/etc/logging_ok: auto-union BitKeeper/triggers/post-commit: Auto merged innobase/row/row0mysql.c: Auto merged myisam/ft_boolean_search.c: Auto merged mysql-test/r/ctype_ucs.result: Auto merged mysql-test/r/distinct.result: Auto merged mysql-test/r/fulltext.result: Auto merged mysql-test/r/select.result: Auto merged mysql-test/r/subselect.result: Auto merged mysql-test/r/union.result: Auto merged mysql-test/t/ctype_ucs.test: Auto merged mysql-test/t/subselect.test: Auto merged mysql-test/t/union.test: Auto merged sql/item_strfunc.cc: Auto merged sql/sql_cache.cc: Auto merged sql/sql_class.cc: Auto merged sql/sql_list.h: Auto merged sql/examples/ha_archive.cc: Auto merged sql/sql_parse.cc: Auto merged sql/sql_select.cc: Auto merged sql/sql_string.h: Auto merged vio/viosocket.c: Auto merged scripts/mysql_create_system_tables.sh: simple merge sql/field.cc: simple merge sql/item.h: simple merge sql/sql_lex.h: simple merge sql/sql_yacc.yy: Merge (join_table_list was not comptely merged. Need to run test to know how things works...) sql/table.cc: Keep code from 5.0, except delted one not needed line strings/ctype-ucs2.c: Auto merge
This commit is contained in:
commit
e2edf02421
28 changed files with 231 additions and 78 deletions
|
|
@ -71,9 +71,11 @@ void Querycache_stream::store_int(uint i)
|
|||
cur_data+= 4;
|
||||
return;
|
||||
}
|
||||
memcpy(cur_data, &i, rest_len);
|
||||
char buf[4];
|
||||
int4store(buf, i);
|
||||
memcpy(cur_data, buf, rest_len);
|
||||
use_next_block();
|
||||
memcpy(cur_data, ((byte*)&i)+rest_len, 4-rest_len);
|
||||
memcpy(cur_data, buf+rest_len, 4-rest_len);
|
||||
cur_data+= 4-rest_len;
|
||||
}
|
||||
|
||||
|
|
@ -186,10 +188,12 @@ uint Querycache_stream::load_int()
|
|||
cur_data+= 4;
|
||||
return result;
|
||||
}
|
||||
memcpy(&result, cur_data, rest_len);
|
||||
char buf[4];
|
||||
memcpy(buf, cur_data, rest_len);
|
||||
use_next_block();
|
||||
memcpy(((byte*)&result)+rest_len, cur_data, 4-rest_len);
|
||||
memcpy(buf+rest_len, cur_data, 4-rest_len);
|
||||
cur_data+= 4-rest_len;
|
||||
result= uint4korr(buf);
|
||||
return result;
|
||||
}
|
||||
|
||||
|
|
@ -270,10 +274,10 @@ int Querycache_stream::load_column(MEM_ROOT *alloc, char** column)
|
|||
return 0;
|
||||
}
|
||||
len--;
|
||||
if (!(*column= (char *)alloc_root(alloc, len + 4 + 1)))
|
||||
if (!(*column= (char *)alloc_root(alloc, len + sizeof(uint) + 1)))
|
||||
return 1;
|
||||
int4store(*column, len);
|
||||
(*column)+= 4;
|
||||
*((uint*)*column)= len;
|
||||
(*column)+= sizeof(uint);
|
||||
load_str_only(*column, len);
|
||||
return 1;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue