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 /client/mysqladmin.cc | |
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 'client/mysqladmin.cc')
-rw-r--r-- | client/mysqladmin.cc | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/client/mysqladmin.cc b/client/mysqladmin.cc index de9fe1f7a70..6fa5d6c73d0 100644 --- a/client/mysqladmin.cc +++ b/client/mysqladmin.cc @@ -175,7 +175,7 @@ static struct my_option my_long_options[] = {"password", 'p', "Password to use when connecting to server. If password is not given it's asked from the tty.", 0, 0, 0, GET_STR, OPT_ARG, 0, 0, 0, 0, 0, 0}, -#ifdef __WIN__ +#ifdef _WIN32 {"pipe", 'W', "Use named pipes to connect to server.", 0, 0, 0, GET_NO_ARG, NO_ARG, 0, 0, 0, 0, 0, 0}, #endif @@ -278,7 +278,7 @@ get_one_option(const struct my_option *opt, const char *argument, const char *fi option_silent++; break; case 'W': -#ifdef __WIN__ +#ifdef _WIN32 opt_protocol = MYSQL_PROTOCOL_PIPE; /* Prioritize pipe if explicit via command line */ @@ -1153,7 +1153,7 @@ static int execute_commands(MYSQL *mysql,int argc, char **argv) { bool old= (find_type(argv[0], &command_typelib, FIND_TYPE_BASIC) == ADMIN_OLD_PASSWORD); -#ifdef __WIN__ +#ifdef _WIN32 size_t pw_len= strlen(typed_password); if (pw_len > 1 && typed_password[0] == '\'' && typed_password[pw_len-1] == '\'') |