From: Date: May 6 2006 12:15am Subject: bk commit into 4.1 tree (acurtis:1.2467) BUG#8706 List-Archive: http://lists.mysql.com/commits/6029 X-Bug: 8706 Message-Id: <200605052215.k45MFa53026685@mail.mysql.com> Below is the list of changes that have just been committed into a local 4.1 repository of antony. When antony does a push these changes will be propagated to the main repository and, within 24 hours after the push, to the public repository. For information on how to access the public repository see http://dev.mysql.com/doc/mysql/en/installing-source-tree.html ChangeSet 1.2467 06/05/05 15:15:23 acurtis@stripped +1 -0 Bug#8706 "temporary table with data directory option fails" For temporary tables, don't make use of table name for file names myisam/mi_create.c 1.48 06/05/05 15:15:20 acurtis@stripped +18 -2 Bug#8706 For temporary tables, don't make use of table name for file names # This is a BitKeeper patch. What follows are the unified diffs for the # set of deltas contained in the patch. The rest of the patch, the part # that BitKeeper cares about, is below these diffs. # User: acurtis # Host: localhost.(none) # Root: /home/antony/work2/p2-bug8706.1 --- 1.47/myisam/mi_create.c 2005-07-23 08:03:31 -07:00 +++ 1.48/myisam/mi_create.c 2006-05-05 15:15:20 -07:00 @@ -519,7 +519,15 @@ int mi_create(const char *name,uint keys if (ci->index_file_name) { - fn_format(filename, ci->index_file_name,"",MI_NAME_IEXT,4); + if (options & HA_OPTION_TMP_TABLE) + { + char *path= strrchr(ci->index_file_name, FN_LIBCHAR); + if (path) *path= '\0'; + fn_format(filename, name, ci->index_file_name, MI_NAME_IEXT, + MY_REPLACE_DIR | MY_UNPACK_FILENAME); + } + else + fn_format(filename, ci->index_file_name,"",MI_NAME_IEXT,4); fn_format(linkname,name, "",MI_NAME_IEXT,4); linkname_ptr=linkname; /* @@ -575,7 +583,15 @@ int mi_create(const char *name,uint keys { if (ci->data_file_name) { - fn_format(filename, ci->data_file_name,"",MI_NAME_DEXT,4); + if (options & HA_OPTION_TMP_TABLE) + { + char *path= strrchr(ci->data_file_name, FN_LIBCHAR); + if (path) *path= '\0'; + fn_format(filename, name, ci->data_file_name, MI_NAME_DEXT, + MY_REPLACE_DIR | MY_UNPACK_FILENAME); + } + else + fn_format(filename, ci->data_file_name,"",MI_NAME_DEXT,4); fn_format(linkname, name, "",MI_NAME_DEXT,4); linkname_ptr=linkname; create_flag=0;