1
0
mirror of https://github.com/MariaDB/server.git synced 2025-08-08 11:22:35 +03:00

Merge 10.4 into 10.5

This commit is contained in:
Marko Mäkelä
2022-07-27 17:17:24 +03:00
278 changed files with 17690 additions and 7421 deletions

View File

@@ -109,7 +109,7 @@ bool ODBCDEF::DefineAM(PGLOBAL g, LPCSTR am, int poff)
Desc = Connect = GetStringCatInfo(g, "Connect", NULL);
if (!Connect && !Catfunc) {
sprintf(g->Message, "Missing connection for ODBC table %s", Name);
snprintf(g->Message, sizeof(g->Message), "Missing connection for ODBC table %s", Name);
return true;
} // endif Connect
@@ -605,7 +605,7 @@ bool TDBODBC::OpenDB(PGLOBAL g)
if ((n = Ocp->GetResultSize(Query->GetStr(), Cnp)) < 0) {
char* msg = PlugDup(g, g->Message);
sprintf(g->Message, "Get result size: %s (rc=%d)", msg, n);
snprintf(g->Message, sizeof(g->Message), "Get result size: %s (rc=%d)", msg, n);
return true;
} else if (n) {
Ocp->m_Rows = n;
@@ -650,7 +650,7 @@ bool TDBODBC::OpenDB(PGLOBAL g)
} else if (Mode == MODE_UPDATE || Mode == MODE_DELETE) {
rc = false; // wait for CheckCond before calling MakeCommand(g);
} else
sprintf(g->Message, "Invalid mode %d", Mode);
snprintf(g->Message, sizeof(g->Message), "Invalid mode %d", Mode);
if (rc) {
Ocp->Close();
@@ -775,7 +775,7 @@ int TDBODBC::ReadDB(PGLOBAL g)
// Send the UPDATE/DELETE command to the remote table
if (!Ocp->ExecSQLcommand(Query->GetStr())) {
sprintf(g->Message, "%s: %d affected rows", TableName, AftRows);
snprintf(g->Message, sizeof(g->Message), "%s: %d affected rows", TableName, AftRows);
if (trace(1))
htrc("%s\n", g->Message);
@@ -851,7 +851,7 @@ int TDBODBC::DeleteDB(PGLOBAL g, int irc)
// Send the DELETE (all) command to the remote table
if (!Ocp->ExecSQLcommand(Query->GetStr())) {
sprintf(g->Message, "%s: %d affected rows", TableName, AftRows);
snprintf(g->Message, sizeof(g->Message), "%s: %d affected rows", TableName, AftRows);
if (trace(1))
htrc("%s\n", g->Message);