mirror of
https://github.com/MariaDB/server.git
synced 2025-08-15 22:37:22 +00:00
Merge 10.4 into 10.5
This commit is contained in:
@ -1,6 +1,6 @@
|
||||
/*
|
||||
Copyright (c) 2000, 2011, Oracle and/or its affiliates
|
||||
Copyright (c) 2010, 2015, MariaDB
|
||||
Copyright (c) 2010, 2020, MariaDB
|
||||
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
@ -769,7 +769,8 @@ int _my_b_cache_read(IO_CACHE *info, uchar *Buffer, size_t Count)
|
||||
info->read_pos=info->buffer+Count;
|
||||
info->read_end=info->buffer+length;
|
||||
info->pos_in_file=pos_in_file;
|
||||
memcpy(Buffer, info->buffer, Count);
|
||||
if (Count)
|
||||
memcpy(Buffer, info->buffer, Count);
|
||||
DBUG_RETURN(0);
|
||||
}
|
||||
|
||||
@ -1270,7 +1271,8 @@ static int _my_b_cache_read_r(IO_CACHE *cache, uchar *Buffer, size_t Count)
|
||||
DBUG_RETURN(1);
|
||||
}
|
||||
cnt= (len > Count) ? Count : len;
|
||||
memcpy(Buffer, cache->read_pos, cnt);
|
||||
if (cnt)
|
||||
memcpy(Buffer, cache->read_pos, cnt);
|
||||
Count -= cnt;
|
||||
Buffer+= cnt;
|
||||
left_length+= cnt;
|
||||
|
Reference in New Issue
Block a user