Skip to content

Commit 383e7b0

Browse files
committed
Mainly to push 1.1 to the new branch(1.1)
Some minor code changes
1 parent cb02a3a commit 383e7b0

File tree

3 files changed

+16
-18
lines changed

3 files changed

+16
-18
lines changed

src/BasePrepareStatement.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ class BasePrepareStatement : public PreparedStatement
6161
MariaDbConnection* connection;
6262

6363
int32_t autoGeneratedKeys;
64-
bool hasLongData =false;
64+
bool hasLongData= false;
6565
//private:
6666
bool useFractionalSeconds;
6767
bool noBackslashEscapes;

src/ClientSidePreparedStatement.cpp

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -222,22 +222,22 @@ namespace mariadb
222222
*/
223223
void ClientSidePreparedStatement::executeInternalBatch(std::size_t size)
224224
{
225+
auto results= new Results(
226+
this,
227+
0,
228+
true,
229+
size,
230+
false,
231+
stmt->getResultSetType(),
232+
stmt->getResultSetConcurrency(),
233+
autoGeneratedKeys,
234+
protocol->getAutoIncrementIncrement(),
235+
nullptr,
236+
nullptr);
225237
stmt->executeQueryPrologue(true);
226-
stmt->setInternalResults(
227-
new Results(
228-
this,
229-
0,
230-
true,
231-
size,
232-
false,
233-
stmt->getResultSetType(),
234-
stmt->getResultSetConcurrency(),
235-
autoGeneratedKeys,
236-
protocol->getAutoIncrementIncrement(),
237-
nullptr,
238-
nullptr));
239-
if (protocol->executeBatchClient(
240-
protocol->isMasterConnection(), stmt->getInternalResults().get(), prepareResult.get(), parameterList, hasLongData)) {
238+
stmt->setInternalResults(results);
239+
if (protocol->executeBatchClient(protocol->isMasterConnection(), results, prepareResult.get(),
240+
parameterList, hasLongData)) {
241241
return;
242242
}
243243

src/protocol/capi/QueryProtocol.cpp

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -282,11 +282,9 @@ namespace capi
282282
bool QueryProtocol::executeBatchClient(
283283
bool mustExecuteOnMaster,
284284
Results* results,
285-
286285
ClientPrepareResult* prepareResult,
287286
std::vector<std::vector<Unique::ParameterHolder>>& parametersList,
288287
bool hasLongData)
289-
290288
{
291289
// ***********************************************************************************************************
292290
// Multiple solution for batching :

0 commit comments

Comments
 (0)