summaryrefslogtreecommitdiff
path: root/storage/myisam/mi_packrec.c
diff options
context:
space:
mode:
authorMarc Alff <marc.alff@sun.com>2009-12-04 18:26:15 -0700
committerMarc Alff <marc.alff@sun.com>2009-12-04 18:26:15 -0700
commit04fe40393d9d0ef81cc6a770bda67ab67fe4154e (patch)
tree9ca152d7f2ac50cfd8b7fca83f87cb06148d97a0 /storage/myisam/mi_packrec.c
parent560e76c567c3551f5a4320acfc954200e8330ad8 (diff)
downloadmariadb-git-04fe40393d9d0ef81cc6a770bda67ab67fe4154e.tar.gz
WL#2360 Performance schema
Part II, engines instrumentation
Diffstat (limited to 'storage/myisam/mi_packrec.c')
-rw-r--r--storage/myisam/mi_packrec.c28
1 files changed, 14 insertions, 14 deletions
diff --git a/storage/myisam/mi_packrec.c b/storage/myisam/mi_packrec.c
index 887a8254979..ee56d86f5ba 100644
--- a/storage/myisam/mi_packrec.c
+++ b/storage/myisam/mi_packrec.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 2000-2006 MySQL AB
+/* Copyright (C) 2000-2006 MySQL AB, 2008-2009 Sun Microsystems, Inc
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
@@ -150,7 +150,7 @@ my_bool _mi_read_pack_info(MI_INFO *info, pbool fix_keys)
file=info->dfile;
my_errno=0;
- if (my_read(file,(uchar*) header,sizeof(header),MYF(MY_NABP)))
+ if (mysql_file_read(file, (uchar*) header, sizeof(header), MYF(MY_NABP)))
{
if (!my_errno)
my_errno=HA_ERR_END_OF_FILE;
@@ -224,9 +224,9 @@ my_bool _mi_read_pack_info(MI_INFO *info, pbool fix_keys)
tmp_buff=share->decode_tables+length;
disk_cache= (uchar*) (tmp_buff+OFFSET_TABLE_SIZE);
- if (my_read(file,disk_cache,
- (uint) (share->pack.header_length-sizeof(header)),
- MYF(MY_NABP)))
+ if (mysql_file_read(file, disk_cache,
+ (uint) (share->pack.header_length-sizeof(header)),
+ MYF(MY_NABP)))
goto err2;
huff_tree_bits=max_bit(trees ? trees-1 : 0);
@@ -717,8 +717,8 @@ int _mi_read_pack_record(MI_INFO *info, my_off_t filepos, uchar *buf)
if (_mi_pack_get_block_info(info, &info->bit_buff, &block_info,
&info->rec_buff, file, filepos))
goto err;
- if (my_read(file,(uchar*) info->rec_buff + block_info.offset ,
- block_info.rec_len - block_info.offset, MYF(MY_NABP)))
+ if (mysql_file_read(file, (uchar*) info->rec_buff + block_info.offset,
+ block_info.rec_len - block_info.offset, MYF(MY_NABP)))
goto panic;
info->update|= HA_STATE_AKTIV;
DBUG_RETURN(_mi_pack_rec_unpack(info, &info->bit_buff, buf,
@@ -1339,9 +1339,9 @@ int _mi_read_rnd_pack_record(MI_INFO *info, uchar *buf,
}
else
{
- if (my_read(info->dfile,(uchar*) info->rec_buff + block_info.offset,
- block_info.rec_len-block_info.offset,
- MYF(MY_NABP)))
+ if (mysql_file_read(info->dfile,
+ (uchar*) info->rec_buff + block_info.offset,
+ block_info.rec_len-block_info.offset, MYF(MY_NABP)))
goto err;
}
info->packed_length=block_info.rec_len;
@@ -1370,11 +1370,11 @@ uint _mi_pack_get_block_info(MI_INFO *myisam, MI_BIT_BUFF *bit_buff,
{
ref_length=myisam->s->pack.ref_length;
/*
- We can't use my_pread() here because mi_read_rnd_pack_record assumes
+ We can't use mysql_file_pread() here because mi_read_rnd_pack_record assumes
position is ok
*/
- my_seek(file,filepos,MY_SEEK_SET,MYF(0));
- if (my_read(file, header,ref_length,MYF(MY_NABP)))
+ mysql_file_seek(file, filepos, MY_SEEK_SET, MYF(0));
+ if (mysql_file_read(file, header, ref_length, MYF(MY_NABP)))
return BLOCK_FATAL_ERROR;
DBUG_DUMP("header",(uchar*) header,ref_length);
}
@@ -1496,7 +1496,7 @@ my_bool _mi_memmap_file(MI_INFO *info)
if (!info->s->file_map)
{
- if (my_seek(info->dfile,0L,MY_SEEK_END,MYF(0)) <
+ if (mysql_file_seek(info->dfile, 0L, MY_SEEK_END, MYF(0)) <
share->state.state.data_file_length+MEMMAP_EXTRA_MARGIN)
{
DBUG_PRINT("warning",("File isn't extended for memmap"));