Skip to content

Commit dcb14e3

Browse files
committed
erge branch '3.1' into 3.3
2 parents df6feae + 9db7314 commit dcb14e3

File tree

6 files changed

+7
-10
lines changed

6 files changed

+7
-10
lines changed

libmariadb/ma_errmsg.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ const char *client_errors[]=
5353
/* 2023 */ "",
5454
/* 2024 */ "",
5555
/* 2025 */ "",
56-
/* 2026 */ "SSL connection error: %-.100s",
56+
/* 2026 */ "TLS/SSL error: %-.100s",
5757
/* 2027 */ "Received malformed packet",
5858
/* 2028 */ "",
5959
/* 2029 */ "",

libmariadb/secure/gnutls.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -889,7 +889,7 @@ static void ma_tls_set_error(MYSQL *mysql, void *ssl, int ssl_errno)
889889
alert_name= gnutls_alert_get_name(alert_desc);
890890
snprintf(ssl_error, MAX_SSL_ERR_LEN, "fatal alert received: %s",
891891
alert_name);
892-
pvio->set_error(mysql, CR_SSL_CONNECTION_ERROR, SQLSTATE_UNKNOWN, ssl_error);
892+
pvio->set_error(mysql, CR_SSL_CONNECTION_ERROR, SQLSTATE_UNKNOWN, 0, ssl_error);
893893
return;
894894
}
895895

libmariadb/secure/ma_schannel.c

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ void ma_schannel_set_sec_error(MARIADB_PVIO* pvio, DWORD ErrorNo)
5252
void ma_schannel_set_win_error(MARIADB_PVIO *pvio, DWORD ErrorNo)
5353
{
5454
char buffer[256];
55-
ma_format_win32_error(buffer, sizeof(buffer), ErrorNo, "SSL connection error: ");
55+
ma_format_win32_error(buffer, sizeof(buffer), ErrorNo, "TLS/SSL error: ");
5656
pvio->set_error(pvio->mysql, CR_SSL_CONNECTION_ERROR, SQLSTATE_UNKNOWN, buffer);
5757
return;
5858
}
@@ -526,8 +526,7 @@ my_bool ma_schannel_verify_certs(MARIADB_TLS *ctls, BOOL verify_server_name)
526526
end:
527527
if (!ret)
528528
{
529-
pvio->set_error(mysql, CR_SSL_CONNECTION_ERROR, SQLSTATE_UNKNOWN,
530-
"SSL connection error: %s", errmsg);
529+
pvio->set_error(mysql, CR_SSL_CONNECTION_ERROR, SQLSTATE_UNKNOWN, 0, errmsg);
531530
}
532531
if (pServerCert)
533532
CertFreeCertificateContext(pServerCert);

libmariadb/secure/schannel.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -225,7 +225,7 @@ static int ma_tls_set_client_certs(MARIADB_TLS *ctls,const CERT_CONTEXT **cert_c
225225
*cert_ctx = schannel_create_cert_context(certfile, keyfile, errmsg, sizeof(errmsg));
226226
if (!*cert_ctx)
227227
{
228-
pvio->set_error(pvio->mysql, CR_SSL_CONNECTION_ERROR, SQLSTATE_UNKNOWN, "SSL connection error: %s", errmsg);
228+
pvio->set_error(pvio->mysql, CR_SSL_CONNECTION_ERROR, SQLSTATE_UNKNOWN, 0, errmsg);
229229
return 1;
230230
}
231231

plugins/auth/sha256_pw.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/************************************************************************************
2-
Copyright (C) 2017, 2021, MariaDB Corporation AB
2+
Copyright (C) 2017, 2022, MariaDB Corporation AB
33
44
This library is free software; you can redistribute it and/or
55
modify it under the terms of the GNU Library General Public

unittest/libmariadb/cursor.c

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -421,11 +421,9 @@ static int test_bug10736(MYSQL *mysql)
421421

422422
for (i= 0; i < 3; i++)
423423
{
424-
int row_no= 0;
425424
rc= mysql_stmt_execute(stmt);
426425
check_stmt_rc(rc, stmt);
427-
while ((rc= mysql_stmt_fetch(stmt)) == 0)
428-
++row_no;
426+
while ((rc= mysql_stmt_fetch(stmt)) == 0);
429427
FAIL_UNLESS(rc == MYSQL_NO_DATA, "rc != MYSQL_NO_DATA");
430428
}
431429
rc= mysql_stmt_close(stmt);

0 commit comments

Comments
 (0)