connectivity/source/drivers/mysqlc/mysqlc_resultsetmetadata.cxx | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
New commits: commit fbd76fbd23b52f5e98021a93c4e73a7844312ff3 Author: Caolán McNamara <[email protected]> AuthorDate: Mon Aug 27 11:55:05 2018 +0100 Commit: Andras Timar <[email protected]> CommitDate: Tue Aug 28 20:29:58 2018 +0200 coverity#1438783 Unchecked return value Change-Id: Ice56d317087dd24d2eef27f2ace5fdf9f4da946d Reviewed-on: https://gerrit.libreoffice.org/59654 Tested-by: Jenkins Reviewed-by: Caolán McNamara <[email protected]> Tested-by: Caolán McNamara <[email protected]> Reviewed-on: https://gerrit.libreoffice.org/59716 Reviewed-by: Andras Timar <[email protected]> Tested-by: Andras Timar <[email protected]> diff --git a/connectivity/source/drivers/mysqlc/mysqlc_resultsetmetadata.cxx b/connectivity/source/drivers/mysqlc/mysqlc_resultsetmetadata.cxx index eeadf2bd03a9..11e1d6996c70 100644 --- a/connectivity/source/drivers/mysqlc/mysqlc_resultsetmetadata.cxx +++ b/connectivity/source/drivers/mysqlc/mysqlc_resultsetmetadata.cxx @@ -63,7 +63,9 @@ sal_Bool SAL_CALL OResultSetMetaData::isCaseSensitive(sal_Int32 column) Reference<XResultSet> rs = stmt->executeQuery(sql.makeStringAndClear()); Reference<XRow> xRow(rs, UNO_QUERY_THROW); - rs->next(); // fetch first and only row + if (!rs->next()) // fetch first and only row + return false; + rtl::OUString sColName = xRow->getString(1); // first column is Collation name return !sColName.isEmpty() && !sColName.endsWith("_ci"); _______________________________________________ Libreoffice-commits mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
