diff options
author | Vladislav Vaintroub <wlad@mariadb.com> | 2021-06-06 13:21:03 +0200 |
---|---|---|
committer | Vladislav Vaintroub <wlad@mariadb.com> | 2021-06-06 13:21:03 +0200 |
commit | 3d6eb7afcfb47cb432f790d0b25c8c1f4ec5bcf3 (patch) | |
tree | 0915add6039e740b9ab08baf215e435480c44526 /mysys/my_access.c | |
parent | 06dd151bb86ad5b87d4d46011f36da1289c01074 (diff) | |
download | mariadb-git-3d6eb7afcfb47cb432f790d0b25c8c1f4ec5bcf3.tar.gz |
MDEV-25602 get rid of __WIN__ in favor of standard _WIN32
This fixed the MySQL bug# 20338 about misuse of double underscore
prefix __WIN__, which was old MySQL's idea of identifying Windows
Replace it by _WIN32 standard symbol for targeting Windows OS
(both 32 and 64 bit)
Not that connect storage engine is not fixed in this patch (must be
fixed in "upstream" branch)
Diffstat (limited to 'mysys/my_access.c')
-rw-r--r-- | mysys/my_access.c | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/mysys/my_access.c b/mysys/my_access.c index 65746295391..81e635d9716 100644 --- a/mysys/my_access.c +++ b/mysys/my_access.c @@ -17,7 +17,7 @@ #include "mysys_priv.h" #include <m_string.h> -#ifdef __WIN__ +#ifdef _WIN32 /* Check a file or path for accessability. @@ -46,7 +46,7 @@ int my_access(const char *path, int amode) return 0; } -#endif /* __WIN__ */ +#endif /* _WIN32 */ /* @@ -150,7 +150,7 @@ int check_if_legal_tablename(const char *name) } -#ifdef __WIN__ +#ifdef _WIN32 /** Checks if the drive letter supplied is valid or not. Valid drive letters are A to Z, both lower case and upper case. @@ -217,10 +217,9 @@ my_bool is_filename_allowed(const char *name __attribute__((unused)), } return TRUE; } /* is_filename_allowed */ -#endif /* __WIN__ */ - -#if defined(__WIN__) || defined(__EMX__) +#endif /* _WIN32 */ +#if defined(_WIN32) /* Check if a path will access a reserved file name that may cause problems @@ -265,4 +264,4 @@ int check_if_legal_filename(const char *path) DBUG_RETURN(0); } -#endif /* defined(__WIN__) || defined(__EMX__) */ +#endif /* defined(_WIN32) */ |