diff options
author | Marko Mäkelä <marko.makela@mariadb.com> | 2019-09-23 10:25:34 +0300 |
---|---|---|
committer | Marko Mäkelä <marko.makela@mariadb.com> | 2019-09-23 10:25:34 +0300 |
commit | c016ea660ede8b7ff75f8ca65f73e2958262263a (patch) | |
tree | c8bc8579c738792f0769ea70f49348dc1baf51b3 /client/mysqldump.c | |
parent | 1bbe8c5e0f6823acd4780d7563e8c02f8b4c5a01 (diff) | |
parent | 2931fd2917cc130e34e5f3d9d6c571a2b013e49c (diff) | |
download | mariadb-git-c016ea660ede8b7ff75f8ca65f73e2958262263a.tar.gz |
Merge 10.2 into 10.3
Diffstat (limited to 'client/mysqldump.c')
-rw-r--r-- | client/mysqldump.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/client/mysqldump.c b/client/mysqldump.c index 88cf4447f18..fff90b1d9e1 100644 --- a/client/mysqldump.c +++ b/client/mysqldump.c @@ -1,6 +1,6 @@ /* Copyright (c) 2000, 2013, Oracle and/or its affiliates. - Copyright (c) 2010, 2017, MariaDB Corporation. + Copyright (c) 2010, 2019, MariaDB Corporation. This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -1081,7 +1081,7 @@ static int get_options(int *argc, char ***argv) my_progname_short); return(EX_USAGE); } - if (strcmp(default_charset, charset_info->csname) && + if (strcmp(default_charset, MYSQL_AUTODETECT_CHARSET_NAME) && !(charset_info= get_charset_by_csname(default_charset, MY_CS_PRIMARY, MYF(MY_WME)))) exit(1); @@ -1546,6 +1546,9 @@ static int switch_character_set_results(MYSQL *mysql, const char *cs_name) char query_buffer[QUERY_LENGTH]; size_t query_length; + if (!strcmp(cs_name, MYSQL_AUTODETECT_CHARSET_NAME)) + cs_name= (char *)my_default_csname(); + /* Server lacks facility. This is not an error, by arbitrary decision . */ if (!server_supports_switching_charsets) return FALSE; |