From 50c49a6979ccf7096bb1b7d8a93d0c495ff12ec1 Mon Sep 17 00:00:00 2001 From: Dennis Oberst Date: Wed, 10 Apr 2024 11:32:04 +0200 Subject: [PATCH] QOCICols: fix warning for -Wdangling-reference .. by playing it safe and taking the QVariant by copy Pick-to: 6.5 Change-Id: I24e0507a912388b7fb17e838a22e8d4c449bcf5b Reviewed-by: Volker Hilsheimer (cherry picked from commit d4f2a5aa401c14dd8dc122bbf25fce9cd7f41cba) Reviewed-by: Qt Cherry-pick Bot --- src/plugins/sqldrivers/oci/qsql_oci.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/plugins/sqldrivers/oci/qsql_oci.cpp b/src/plugins/sqldrivers/oci/qsql_oci.cpp index 24bee9179a3..08f2397ecf8 100644 --- a/src/plugins/sqldrivers/oci/qsql_oci.cpp +++ b/src/plugins/sqldrivers/oci/qsql_oci.cpp @@ -1429,7 +1429,7 @@ bool QOCICols::execBatch(QOCIResultPrivate *d, QVariantList &boundValues, bool a // we may now populate column with data for (uint row = 0; row < col.recordCount; ++row) { - const QVariant &val = boundValues.at(i).toList().at(row); + const QVariant val = boundValues.at(i).toList().at(row); if (QSqlResultPrivate::isVariantNull(val) && !d->isOutValue(i)) { columns[i].indicators[row] = -1;