summaryrefslogtreecommitdiff
path: root/connectivity/source/drivers/file/FResultSet.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'connectivity/source/drivers/file/FResultSet.cxx')
-rw-r--r--connectivity/source/drivers/file/FResultSet.cxx21
1 files changed, 4 insertions, 17 deletions
diff --git a/connectivity/source/drivers/file/FResultSet.cxx b/connectivity/source/drivers/file/FResultSet.cxx
index fdf3a4e47d84..5612c68feedf 100644
--- a/connectivity/source/drivers/file/FResultSet.cxx
+++ b/connectivity/source/drivers/file/FResultSet.cxx
@@ -29,6 +29,7 @@
#include <cppuhelper/typeprovider.hxx>
#include <connectivity/dbtools.hxx>
#include <cppuhelper/propshlp.hxx>
+#include <o3tl/safeint.hxx>
#include <sal/log.hxx>
#include <iterator>
#include <com/sun/star/sdbc/ResultSetType.hpp>
@@ -41,7 +42,7 @@
#include <comphelper/types.hxx>
#include <resource/sharedresources.hxx>
#include <strings.hrc>
-#include <tools/diagnose_ex.h>
+#include <comphelper/diagnose_ex.hxx>
using namespace ::comphelper;
using namespace connectivity;
@@ -921,7 +922,7 @@ bool OResultSet::Move(IResultSetHelper::Movement eCursorPosition, sal_Int32 nOff
// The FileCursor is outside of the valid range, if:
// a.) m_nRowPos < 1
// b.) a KeySet exists and m_nRowPos > m_pFileSet->size()
- if (m_nRowPos < 0 || (m_pFileSet->isFrozen() && eCursorPosition != IResultSetHelper::BOOKMARK && m_nRowPos >= static_cast<sal_Int32>(m_pFileSet->size()) )) // && m_pFileSet->IsFrozen()
+ if (m_nRowPos < 0 || (m_pFileSet->isFrozen() && eCursorPosition != IResultSetHelper::BOOKMARK && o3tl::make_unsigned(m_nRowPos) >= m_pFileSet->size() )) // && m_pFileSet->IsFrozen()
{
goto Error;
}
@@ -1380,19 +1381,6 @@ void OResultSet::OpenImpl()
m_nFilePos = 0;
}
-Sequence< sal_Int8 > OResultSet::getUnoTunnelId()
-{
- static const comphelper::UnoIdInit implId;
- return implId.getSeq();
-}
-
-// css::lang::XUnoTunnel
-
-sal_Int64 OResultSet::getSomething( const Sequence< sal_Int8 > & rId )
-{
- return comphelper::getSomethingImpl(rId, this);
-}
-
void OResultSet::setBoundedColumns(const OValueRefRow& _rRow,
const OValueRefRow& _rSelectRow,
const ::rtl::Reference<connectivity::OSQLColumns>& _rxColumns,
@@ -1527,8 +1515,7 @@ Reference< css::beans::XPropertySetInfo > SAL_CALL OResultSet::getPropertySetInf
void OResultSet::doTableSpecials(const OSQLTable& _xTable)
{
- Reference<css::lang::XUnoTunnel> xTunnel(_xTable, UNO_QUERY_THROW);
- m_pTable = comphelper::getFromUnoTunnel<OFileTable>(xTunnel);
+ m_pTable = dynamic_cast<OFileTable*>(_xTable.get());
assert(m_pTable.is());
}