Skip to content

Commit e1caa4b

Browse files
committed
don't use ssl for windows named pipes - it doesn't work
1 parent ce9385b commit e1caa4b

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

client/mysql.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1491,7 +1491,7 @@ static bool do_connect(MYSQL *mysql, const char *host, const char *user,
14911491
if (opt_secure_auth)
14921492
mysql_options(mysql, MYSQL_SECURE_AUTH, (char *) &opt_secure_auth);
14931493
#if defined(HAVE_OPENSSL) && !defined(EMBEDDED_LIBRARY)
1494-
if (opt_use_ssl)
1494+
if (opt_use_ssl && opt_protocol <= MYSQL_PROTOCOL_SOCKET)
14951495
{
14961496
mysql_ssl_set(mysql, opt_ssl_key, opt_ssl_cert, opt_ssl_ca,
14971497
opt_ssl_capath, opt_ssl_cipher);

extra/mariabackup/backup_mysql.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ xb_mysql_connect()
131131
opt_socket ? opt_socket : "not set");
132132

133133
#ifdef HAVE_OPENSSL
134-
if (opt_use_ssl)
134+
if (opt_use_ssl && opt_protocol <= MYSQL_PROTOCOL_SOCKET)
135135
{
136136
mysql_ssl_set(connection, opt_ssl_key, opt_ssl_cert,
137137
opt_ssl_ca, opt_ssl_capath,

0 commit comments

Comments
 (0)