Skip to content

Commit 06acf4b

Browse files
committed
Connector/C submodule updated to v3.4.6
Also one new test for the result requiring large packet
1 parent 125389a commit 06acf4b

File tree

4 files changed

+30
-6
lines changed

4 files changed

+30
-6
lines changed

driver/ma_connection.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -828,7 +828,7 @@ SQLRETURN MADB_Dbc::CoreConnect(MYSQL* _mariadb, MADB_Dsn *Dsn, MADB_Error* _Err
828828
NeedComma= 1;
829829
}
830830
strcpy(Ptr, TlsVersionName[i]);
831-
Ptr += strlen(TlsVersionName[i]);
831+
Ptr+= strlen(TlsVersionName[i]);
832832
}
833833
}
834834
mysql_optionsv(_mariadb, MARIADB_OPT_TLS_VERSION, (void *)TlsVersion);

libmariadb

test/result2.c

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1643,6 +1643,29 @@ ODBC_TEST(t_odbc429)
16431643
}
16441644

16451645

1646+
ODBC_TEST(t_largerpacket)
1647+
{
1648+
SQLLEN len= 0;
1649+
SQLCHAR buf[256];
1650+
1651+
OK_SIMPLE_STMT(Stmt, "SELECT REPEAT('A', 20000000)");
1652+
CHECK_STMT_RC(Stmt, SQLFetch(Stmt));
1653+
CHECK_STMT_RC(Stmt, SQLGetData(Stmt, 1, SQL_C_CHAR, buf, sizeof(buf), &len));
1654+
if (len != SQL_NULL_DATA && len != 20000000)
1655+
{
1656+
diag("Depending on max_allowed_packet size the length of fetched value should be either SQL_NULL_DATA(-1) or 20000000,"
1657+
" but it is %lld", (long long)len);
1658+
return FAIL;
1659+
}
1660+
CHECK_STMT_RC(Stmt, SQLFreeStmt(Stmt, SQL_CLOSE));
1661+
/* Just to verify that we haven't lost the connection */
1662+
OK_SIMPLE_STMT(Stmt, "SELECT 1");
1663+
CHECK_STMT_RC(Stmt, SQLFreeStmt(Stmt, SQL_CLOSE));
1664+
1665+
return OK;
1666+
}
1667+
1668+
16461669
MA_ODBC_TESTS my_tests[]=
16471670
{
16481671
{t_bug32420, "t_bug32420"},
@@ -1677,6 +1700,7 @@ MA_ODBC_TESTS my_tests[]=
16771700
{t_odbc214, "t_odbc214_medium"},
16781701
{t_odbc350, "t_odbc350_bit_in_subquery"},
16791702
{t_odbc429, "t_odbc429odbc425_moreresults_after_error"},
1703+
{t_largerpacket,"larger_max_packet"},
16801704
{NULL, NULL}
16811705
};
16821706

test/tran.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -252,10 +252,10 @@ ODBC_TEST(t_isolation3)
252252
MA_ODBC_TESTS my_tests[]=
253253
{
254254
{my_transaction,"my_transaction"},
255-
{t_tran, "t_tran"},
256-
{t_isolation, "t_isolation"},
257-
{t_isolation2, "t_isolation2_value_change_tracking"},
258-
{t_isolation3, "t_isolation3_set_before_connect"},
255+
{t_tran, "t_tran"},
256+
{t_isolation, "t_isolation"},
257+
{t_isolation2, "t_isolation2_value_change_tracking"},
258+
{t_isolation3, "t_isolation3_set_before_connect"},
259259
{NULL, NULL}
260260
};
261261

0 commit comments

Comments
 (0)