diff --git a/mysql-test/r/func_gconcat.result b/mysql-test/r/func_gconcat.result index bf96727a6a7..d518cff45cf 100644 --- a/mysql-test/r/func_gconcat.result +++ b/mysql-test/r/func_gconcat.result @@ -169,7 +169,7 @@ select REQ_ID, Group_Concat(URL) as URL from T_URL, T_REQUEST where T_REQUEST.URL_ID = T_URL.URL_ID group by REQ_ID; REQ_ID URL 1 www.host.com -5 www.host.com,www.google.com,www.help.com +5 www.google.com,www.help.com,www.host.com drop table T_URL; drop table T_REQUEST; select group_concat(sum(a)) from t1 group by grp; diff --git a/mysql-test/r/grant_cache.result b/mysql-test/r/grant_cache.result index 0ffc48ad879..c8ae0b4d9b3 100644 --- a/mysql-test/r/grant_cache.result +++ b/mysql-test/r/grant_cache.result @@ -122,7 +122,7 @@ select "user4"; user4 user4 select a from t1; -ERROR 42000: No Database Selected +ERROR 3D000: No Database Selected select * from mysqltest.t1,test.t1; a b c a 1 1 1 test.t1 diff --git a/mysys/mf_loadpath.c b/mysys/mf_loadpath.c index 2c90d9f90a6..a46b43c34d4 100644 --- a/mysys/mf_loadpath.c +++ b/mysys/mf_loadpath.c @@ -28,6 +28,7 @@ my_string my_load_path(my_string to, const char *path, const char *own_path_prefix) { char buff[FN_REFLEN]; + int is_cur; DBUG_ENTER("my_load_path"); DBUG_PRINT("enter",("path: %s prefix: %s",path, own_path_prefix ? own_path_prefix : "")); @@ -35,12 +36,14 @@ my_string my_load_path(my_string to, const char *path, if ((path[0] == FN_HOMELIB && path[1] == FN_LIBCHAR) || test_if_hard_path(path)) VOID(strmov(buff,path)); - else if ((path[0] == FN_CURLIB && path[1] == FN_LIBCHAR) || + else if ((is_cur=(path[0] == FN_CURLIB && path[1] == FN_LIBCHAR)) || (is_prefix((gptr) path,FN_PARENTDIR)) || ! own_path_prefix) { - if (! my_getwd(buff,(uint) (FN_REFLEN+2-strlen(path)),MYF(0))) - VOID(strcat(buff,path+2)); + if (is_cur) + is_cur=2; /* Remove current dir */ + if (! my_getwd(buff,(uint) (FN_REFLEN-strlen(path)+is_cur),MYF(0))) + VOID(strcat(buff,path+is_cur)); else VOID(strmov(buff,path)); /* Return org file name */ }