summaryrefslogtreecommitdiff
path: root/sql/ha_myisam.cc
diff options
context:
space:
mode:
authorunknown <ingo@mysql.com>2005-03-04 11:37:45 +0100
committerunknown <ingo@mysql.com>2005-03-04 11:37:45 +0100
commit7bd7643ab7b1df5de942422ef0a037718881b3b3 (patch)
treebe5541209e5f5e84db880427fffd18b0e7e9ceb8 /sql/ha_myisam.cc
parentaec0408ba9634bc15be77b8507ca8b83ff609e24 (diff)
parente54b545a966a92677242d6e6f904a10eb73cb707 (diff)
downloadmariadb-git-7bd7643ab7b1df5de942422ef0a037718881b3b3.tar.gz
Merge with after merge fix
BitKeeper/deleted/.del-create.c~96cecc433c0c2242: Auto merged include/my_global.h: Auto merged myisam/mi_create.c: Auto merged sql/ha_myisam.cc: Auto merged sql/mysql_priv.h: Auto merged BitKeeper/deleted/.del-errmsg.txt~f96b7055cac394e: Auto merged BitKeeper/deleted/.del-mrg_create.c~b747c8ec2b801f6: Auto merged sql/table.cc: Auto merged sql/sql_udf.cc: After merge fix
Diffstat (limited to 'sql/ha_myisam.cc')
-rw-r--r--sql/ha_myisam.cc18
1 files changed, 11 insertions, 7 deletions
diff --git a/sql/ha_myisam.cc b/sql/ha_myisam.cc
index ad7e775aacf..2179eaa7f8f 100644
--- a/sql/ha_myisam.cc
+++ b/sql/ha_myisam.cc
@@ -1350,7 +1350,7 @@ int ha_myisam::create(const char *name, register TABLE *table_arg,
HA_CREATE_INFO *info)
{
int error;
- uint i,j,recpos,minpos,fieldpos,temp_length,length;
+ uint i,j,recpos,minpos,fieldpos,temp_length,length, create_flags= 0;
bool found_real_auto_increment=0;
enum ha_base_keytype type;
char buff[FN_REFLEN];
@@ -1538,17 +1538,21 @@ int ha_myisam::create(const char *name, register TABLE *table_arg,
create_info.data_file_name= info->data_file_name;
create_info.index_file_name= info->index_file_name;
+ if (info->options & HA_LEX_CREATE_TMP_TABLE)
+ create_flags|= HA_CREATE_TMP_TABLE;
+ if (options & HA_OPTION_PACK_RECORD)
+ create_flags|= HA_PACK_RECORD;
+ if (options & HA_OPTION_CHECKSUM)
+ create_flags|= HA_CREATE_CHECKSUM;
+ if (options & HA_OPTION_DELAY_KEY_WRITE)
+ create_flags|= HA_CREATE_DELAY_KEY_WRITE;
+
/* TODO: Check that the following fn_format is really needed */
error=mi_create(fn_format(buff,name,"","",2+4),
share->keys,keydef,
(uint) (recinfo_pos-recinfo), recinfo,
0, (MI_UNIQUEDEF*) 0,
- &create_info,
- (((options & HA_OPTION_PACK_RECORD) ? HA_PACK_RECORD : 0) |
- ((options & HA_OPTION_CHECKSUM) ? HA_CREATE_CHECKSUM : 0) |
- ((options & HA_OPTION_DELAY_KEY_WRITE) ?
- HA_CREATE_DELAY_KEY_WRITE : 0)));
-
+ &create_info, create_flags);
my_free((gptr) recinfo,MYF(0));
DBUG_RETURN(error);