[Libreoffice-commits] core.git: connectivity/source

Caolán McNamara (via logerrit) logerrit at kemper.freedesktop.org
Fri Sep 24 13:07:49 UTC 2021


 connectivity/source/drivers/dbase/DTable.cxx |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit b0886a4dc7e5a34ab3ee302b6ad6c30c0ce6a0af
Author:     Caolán McNamara <caolanm at redhat.com>
AuthorDate: Fri Sep 24 12:05:52 2021 +0100
Commit:     Caolán McNamara <caolanm at redhat.com>
CommitDate: Fri Sep 24 15:07:14 2021 +0200

    use a min of 1 as 0 triggers refreshHeader to reload
    
    Change-Id: Iecc6adcce7e32a205f0c9cc6d634d703ea88de06
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122573
    Tested-by: Jenkins
    Reviewed-by: Caolán McNamara <caolanm at redhat.com>

diff --git a/connectivity/source/drivers/dbase/DTable.cxx b/connectivity/source/drivers/dbase/DTable.cxx
index a306474817be..6af3bdc852e7 100644
--- a/connectivity/source/drivers/dbase/DTable.cxx
+++ b/connectivity/source/drivers/dbase/DTable.cxx
@@ -523,7 +523,7 @@ void ODbaseTable::construct()
         {
             SAL_WARN("connectivity.drivers", "Parsing error: " << nMaxPossibleRecords <<
                      " max possible records, but " << m_aHeader.nbRecords << " claimed, truncating");
-            m_aHeader.nbRecords = nMaxPossibleRecords;
+            m_aHeader.nbRecords = std::max(nMaxPossibleRecords, static_cast<size_t>(1));
         }
     }
 


More information about the Libreoffice-commits mailing list