From 3bcbaf6cbf18dc04ee2495cc6cd2bf8aa399ebb5 Mon Sep 17 00:00:00 2001 From: Georgi Kodinov Date: Wed, 9 Jul 2008 13:03:48 +0300 Subject: fixed a compilation warning on windows 64. --- mysys/default.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'mysys/default.c') diff --git a/mysys/default.c b/mysys/default.c index bf32261129b..b7eb963e395 100644 --- a/mysys/default.c +++ b/mysys/default.c @@ -1017,7 +1017,7 @@ static const char *my_get_module_parent(char *buf, size_t size) { char *last= NULL; char *end; - if (!GetModuleFileName(NULL, buf, size)) + if (!GetModuleFileName(NULL, buf, (DWORD) size)) return NULL; end= strend(buf); -- cgit v1.2.1 From aa5731dad97ec8ac95d2e4cdd43211460d546b29 Mon Sep 17 00:00:00 2001 From: Timothy Smith Date: Wed, 16 Jul 2008 16:58:45 -0600 Subject: Bug #38180 options are read from ~/my.cnf instead of ~/.my.cnf Pull out some of unpack_dirname() into normalize_dirname(); this new function does not expand "~" to the home directory. Use this function in unpack_dirname(), and use it during init_default_directories() to remove duplicate entries without losing track of which directory is a user's home dir. --- mysys/default.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'mysys/default.c') diff --git a/mysys/default.c b/mysys/default.c index b7eb963e395..b709b33e2f8 100644 --- a/mysys/default.c +++ b/mysys/default.c @@ -965,8 +965,7 @@ static int add_directory(MEM_ROOT *alloc, const char *dir, const char **dirs) char *p; my_bool err __attribute__((unused)); - /* Normalize directory name */ - len= unpack_dirname(buf, dir); + len= normalize_dirname(buf, dir); if (!(p= strmake_root(alloc, buf, len))) return 1; /* Failure */ /* Should never fail if DEFAULT_DIRS_SIZE is correct size */ -- cgit v1.2.1