summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorunknown <serg@serg.mylan>2005-06-15 22:49:52 +0200
committerunknown <serg@serg.mylan>2005-06-15 22:49:52 +0200
commit9fb9133f2c1f0524ddbb174c27621ac47fe436b2 (patch)
tree84c961bea5df75fd0590252f56461ebc2108f7bc
parentc7a681ff94d3f39360a53d940398931dd55aad66 (diff)
downloadmariadb-git-9fb9133f2c1f0524ddbb174c27621ac47fe436b2.tar.gz
cleanup for bug#11167.
portability alignment issues.
-rw-r--r--sql/sql_select.cc10
1 files changed, 5 insertions, 5 deletions
diff --git a/sql/sql_select.cc b/sql/sql_select.cc
index 2cb650cda2a..41b56ae888c 100644
--- a/sql/sql_select.cc
+++ b/sql/sql_select.cc
@@ -8112,9 +8112,9 @@ store_record_in_cache(JOIN_CACHE *cache)
end > str && end[-1] == ' ' ;
end--) ;
length=(uint) (end-str);
- memcpy(pos+sizeof(uint), str, length);
- *((uint *) pos)= length;
- pos+= length+sizeof(uint);
+ memcpy(pos+2, str, length);
+ int2store(pos, length);
+ pos+= length+2;
}
else
{
@@ -8177,9 +8177,9 @@ read_cached_record(JOIN_TAB *tab)
{
if (copy->strip)
{
- memcpy(copy->str, pos+sizeof(uint), length= *((uint *) pos));
+ memcpy(copy->str, pos+2, length= uint2korr(pos));
memset(copy->str+length, ' ', copy->length-length);
- pos+= sizeof(uint)+length;
+ pos+= 2+length;
}
else
{