Commit dcfe258f authored by unknown's avatar unknown

Bug #8183 MERGE and SYM cause wrong SHOW CREATE TABLE

Without this patch, all file elements in info have symlink resolved
pathnames.  This means append_create_info does not  have any way
of showing the correct database name when a symlinked database is used.


myisam/mi_open.c:
  store name (not symlinked resolved) instead of org_name (symlink resolved)
  in info.
parent d974ce93
......@@ -515,7 +515,7 @@ MI_INFO *mi_open(const char *name, int mode, uint open_flags)
share->base.max_key_length),
&info.lastkey,share->base.max_key_length*3+1,
&info.first_mbr_key, share->base.max_key_length,
&info.filename,strlen(org_name)+1,
&info.filename,strlen(name)+1,
&info.rtree_recursion_state,have_rtree ? 1024 : 0,
NullS))
goto err;
......@@ -524,7 +524,7 @@ MI_INFO *mi_open(const char *name, int mode, uint open_flags)
if (!have_rtree)
info.rtree_recursion_state= NULL;
strmov(info.filename,org_name);
strmov(info.filename,name);
memcpy(info.blobs,share->blobs,sizeof(MI_BLOB)*share->base.blobs);
info.lastkey2=info.lastkey+share->base.max_key_length;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment