summaryrefslogtreecommitdiff
path: root/storage/maria/ma_dynrec.c
diff options
context:
space:
mode:
authorKentoku SHIBA <kentokushiba@gmail.com>2021-04-28 16:45:50 +0900
committerGitHub <noreply@github.com>2021-04-28 16:45:50 +0900
commit977115add60f0f9d6258e5ebcb512a1c97492691 (patch)
tree6c5dff26ceecebc6607a180b98b8711b88dd25f7 /storage/maria/ma_dynrec.c
parentb5d4964d1e56f91a0f129e72e850ed6220c52002 (diff)
parent4cd92143eae9b397589e5b449d1a85c43b3e4f6b (diff)
downloadmariadb-git-977115add60f0f9d6258e5ebcb512a1c97492691.tar.gz
Merge branch '10.4' into bb-10.4-MDEV-22265bb-10.4-MDEV-22265
Diffstat (limited to 'storage/maria/ma_dynrec.c')
-rw-r--r--storage/maria/ma_dynrec.c13
1 files changed, 8 insertions, 5 deletions
diff --git a/storage/maria/ma_dynrec.c b/storage/maria/ma_dynrec.c
index ae6fc57c114..829e5b5cd02 100644
--- a/storage/maria/ma_dynrec.c
+++ b/storage/maria/ma_dynrec.c
@@ -1477,6 +1477,8 @@ int _ma_read_dynamic_record(MARIA_HA *info, uchar *buf,
File file;
uchar *UNINIT_VAR(to);
uint UNINIT_VAR(left_length);
+ MARIA_SHARE *share= info->s;
+ myf flag= MY_WME | (share->temporary ? MY_THREAD_SPECIFIC : 0);
DBUG_ENTER("_ma_read_dynamic_record");
if (filepos == HA_OFFSET_ERROR)
@@ -1507,13 +1509,13 @@ int _ma_read_dynamic_record(MARIA_HA *info, uchar *buf,
if (block_of_record++ == 0) /* First block */
{
info->cur_row.total_length= block_info.rec_len;
- if (block_info.rec_len > (uint) info->s->base.max_pack_length)
+ if (block_info.rec_len > (uint) share->base.max_pack_length)
goto panic;
- if (info->s->base.blobs)
+ if (share->base.blobs)
{
if (_ma_alloc_buffer(&info->rec_buff, &info->rec_buff_size,
block_info.rec_len +
- info->s->base.extra_rec_buff_size))
+ share->base.extra_rec_buff_size, flag))
goto err;
}
to= info->rec_buff;
@@ -1549,7 +1551,7 @@ int _ma_read_dynamic_record(MARIA_HA *info, uchar *buf,
there is no equivalent without seeking. We are at the right
position already. :(
*/
- if (info->s->file_read(info, to, block_info.data_len,
+ if (share->file_read(info, to, block_info.data_len,
filepos, MYF(MY_NABP)))
goto panic;
left_length-=block_info.data_len;
@@ -1769,6 +1771,7 @@ int _ma_read_rnd_dynamic_record(MARIA_HA *info,
uchar *UNINIT_VAR(to);
MARIA_BLOCK_INFO block_info;
MARIA_SHARE *share= info->s;
+ myf flag= MY_WME | (share->temporary ? MY_THREAD_SPECIFIC : 0);
DBUG_ENTER("_ma_read_rnd_dynamic_record");
#ifdef MARIA_EXTERNAL_LOCKING
@@ -1859,7 +1862,7 @@ int _ma_read_rnd_dynamic_record(MARIA_HA *info,
{
if (_ma_alloc_buffer(&info->rec_buff, &info->rec_buff_size,
block_info.rec_len +
- info->s->base.extra_rec_buff_size))
+ share->base.extra_rec_buff_size, flag))
goto err;
}
to= info->rec_buff;