Tag: cws_src680_dba202c
User: oj      
Date: 05/12/05 03:56:14

Modified:
 /dba/dbaccess/source/core/api/
  datacolumn.cxx

Log:
 #128689# check m_xRow if null throw an disposedexception

File Changes:

Directory: /dba/dbaccess/source/core/api/
=========================================

File [changed]: datacolumn.cxx
Url: 
http://dba.openoffice.org/source/browse/dba/dbaccess/source/core/api/datacolumn.cxx?r1=1.6&r2=1.6.58.1
Delta lines:  +40 -41
---------------------
--- datacolumn.cxx      8 Sep 2005 10:05:27 -0000       1.6
+++ datacolumn.cxx      5 Dec 2005 11:56:11 -0000       1.6.58.1
@@ -4,9 +4,9 @@
  *
  *  $RCSfile: datacolumn.cxx,v $
  *
- *  $Revision: 1.6 $
+ *  $Revision: 1.6.58.1 $
  *
- *  last change: $Author: rt $ $Date: 2005/09/08 10:05:27 $
+ *  last change: $Author: oj $ $Date: 2005/12/05 11:56:11 $
  *
  *  The Contents of this file are made available subject to
  *  the terms of GNU Lesser General Public License Version 2.1.
@@ -151,7 +151,6 @@
 {
        OResultColumn::disposing();
 
-       MutexGuard aGuard(m_aMutex);
        m_xRow = NULL;
        m_xRowUpdate = NULL;
 }
@@ -161,7 +160,7 @@
 sal_Bool ODataColumn::wasNull(void) throw( SQLException, RuntimeException )
 {
        MutexGuard aGuard(m_aMutex);
-       ::connectivity::checkDisposed(OColumnBase::rBHelper.bDisposed);
+       ::connectivity::checkDisposed(!m_xRow.is());
        
        return m_xRow->wasNull();
 }
@@ -170,7 +169,7 @@
 rtl::OUString ODataColumn::getString(void) throw( SQLException, 
RuntimeException )
 {
        MutexGuard aGuard(m_aMutex);
-       ::connectivity::checkDisposed(OColumnBase::rBHelper.bDisposed);
+       ::connectivity::checkDisposed(!m_xRow.is());
 
        return m_xRow->getString(m_nPos);
 }
@@ -179,7 +178,7 @@
 sal_Bool ODataColumn::getBoolean(void) throw( SQLException, RuntimeException )
 {
        MutexGuard aGuard(m_aMutex);
-       ::connectivity::checkDisposed(OColumnBase::rBHelper.bDisposed);
+       ::connectivity::checkDisposed(!m_xRow.is());
 
        return m_xRow->getBoolean(m_nPos);
 }
@@ -188,7 +187,7 @@
 sal_Int8 ODataColumn::getByte(void) throw( SQLException, RuntimeException )
 {
        MutexGuard aGuard(m_aMutex);
-       ::connectivity::checkDisposed(OColumnBase::rBHelper.bDisposed);
+       ::connectivity::checkDisposed(!m_xRow.is());
 
        return m_xRow->getByte(m_nPos);
 }
@@ -197,7 +196,7 @@
 sal_Int16 ODataColumn::getShort(void) throw( SQLException, RuntimeException )
 {
        MutexGuard aGuard(m_aMutex);
-       ::connectivity::checkDisposed(OColumnBase::rBHelper.bDisposed);
+       ::connectivity::checkDisposed(!m_xRow.is());
 
        return m_xRow->getShort(m_nPos);
 }
@@ -206,7 +205,7 @@
 sal_Int32 ODataColumn::getInt(void) throw( SQLException, RuntimeException )
 {
        MutexGuard aGuard(m_aMutex);
-       ::connectivity::checkDisposed(OColumnBase::rBHelper.bDisposed);
+       ::connectivity::checkDisposed(!m_xRow.is());
 
        return m_xRow->getInt(m_nPos);
 }
@@ -215,7 +214,7 @@
 sal_Int64 ODataColumn::getLong(void) throw( SQLException, RuntimeException )
 {
        MutexGuard aGuard(m_aMutex);
-       ::connectivity::checkDisposed(OColumnBase::rBHelper.bDisposed);
+       ::connectivity::checkDisposed(!m_xRow.is());
 
        return m_xRow->getLong(m_nPos);
 }
@@ -224,7 +223,7 @@
 float ODataColumn::getFloat(void) throw( SQLException, RuntimeException )
 {
        MutexGuard aGuard(m_aMutex);
-       ::connectivity::checkDisposed(OColumnBase::rBHelper.bDisposed);
+       ::connectivity::checkDisposed(!m_xRow.is());
 
        return m_xRow->getFloat(m_nPos);
 }
@@ -232,7 +231,7 @@
 double ODataColumn::getDouble(void) throw( SQLException, RuntimeException )
 {
        MutexGuard aGuard(m_aMutex);
-       ::connectivity::checkDisposed(OColumnBase::rBHelper.bDisposed);
+       ::connectivity::checkDisposed(!m_xRow.is());
 
        return m_xRow->getDouble(m_nPos);
 }
@@ -241,7 +240,7 @@
 Sequence< sal_Int8 > ODataColumn::getBytes(void) throw( SQLException, 
RuntimeException )
 {
        MutexGuard aGuard(m_aMutex);
-       ::connectivity::checkDisposed(OColumnBase::rBHelper.bDisposed);
+       ::connectivity::checkDisposed(!m_xRow.is());
 
        return m_xRow->getBytes(m_nPos);
 }
@@ -249,7 +248,7 @@
 com::sun::star::util::Date ODataColumn::getDate(void) throw( SQLException, 
RuntimeException )
 {
        MutexGuard aGuard(m_aMutex);
-       ::connectivity::checkDisposed(OColumnBase::rBHelper.bDisposed);
+       ::connectivity::checkDisposed(!m_xRow.is());
 
        return m_xRow->getDate(m_nPos);
 }
@@ -258,7 +257,7 @@
 com::sun::star::util::Time ODataColumn::getTime(void) throw( SQLException, 
RuntimeException )
 {
        MutexGuard aGuard(m_aMutex);
-       ::connectivity::checkDisposed(OColumnBase::rBHelper.bDisposed);
+       ::connectivity::checkDisposed(!m_xRow.is());
 
        return m_xRow->getTime(m_nPos);
 }
@@ -266,7 +265,7 @@
 com::sun::star::util::DateTime ODataColumn::getTimestamp(void) throw( 
SQLException, RuntimeException )
 {
        MutexGuard aGuard(m_aMutex);
-       ::connectivity::checkDisposed(OColumnBase::rBHelper.bDisposed);
+       ::connectivity::checkDisposed(!m_xRow.is());
 
        return m_xRow->getTimestamp(m_nPos);
 }
@@ -275,7 +274,7 @@
 Reference< ::com::sun::star::io::XInputStream >  
ODataColumn::getBinaryStream(void) throw( SQLException, RuntimeException )
 {
        MutexGuard aGuard(m_aMutex);
-       ::connectivity::checkDisposed(OColumnBase::rBHelper.bDisposed);
+       ::connectivity::checkDisposed(!m_xRow.is());
 
        return m_xRow->getBinaryStream(m_nPos);
 }
@@ -284,7 +283,7 @@
 Reference< ::com::sun::star::io::XInputStream >  
ODataColumn::getCharacterStream(void) throw( SQLException, RuntimeException )
 {
        MutexGuard aGuard(m_aMutex);
-       ::connectivity::checkDisposed(OColumnBase::rBHelper.bDisposed);
+       ::connectivity::checkDisposed(!m_xRow.is());
 
        return m_xRow->getCharacterStream(m_nPos);
 }
@@ -293,7 +292,7 @@
 Any ODataColumn::getObject(const Reference< 
::com::sun::star::container::XNameAccess > & typeMap) throw( SQLException, 
RuntimeException )
 {
        MutexGuard aGuard(m_aMutex);
-       ::connectivity::checkDisposed(OColumnBase::rBHelper.bDisposed);
+       ::connectivity::checkDisposed(!m_xRow.is());
 
        return m_xRow->getObject(m_nPos, typeMap);
 }
@@ -302,7 +301,7 @@
 Reference< XRef >  ODataColumn::getRef(void) throw( SQLException, 
RuntimeException )
 {
        MutexGuard aGuard(m_aMutex);
-       ::connectivity::checkDisposed(OColumnBase::rBHelper.bDisposed);
+       ::connectivity::checkDisposed(!m_xRow.is());
 
        return m_xRow->getRef(m_nPos);
 }
@@ -311,7 +310,7 @@
 Reference< XBlob >  ODataColumn::getBlob(void) throw( SQLException, 
RuntimeException )
 {
        MutexGuard aGuard(m_aMutex);
-       ::connectivity::checkDisposed(OColumnBase::rBHelper.bDisposed);
+       ::connectivity::checkDisposed(!m_xRow.is());
 
        return m_xRow->getBlob(m_nPos);
 }
@@ -320,7 +319,7 @@
 Reference< XClob >  ODataColumn::getClob(void) throw( SQLException, 
RuntimeException )
 {
        MutexGuard aGuard(m_aMutex);
-       ::connectivity::checkDisposed(OColumnBase::rBHelper.bDisposed);
+       ::connectivity::checkDisposed(!m_xRow.is());
 
        return m_xRow->getClob(m_nPos);
 }
@@ -329,7 +328,7 @@
 Reference< XArray >  ODataColumn::getArray(void) throw( SQLException, 
RuntimeException )
 {
        MutexGuard aGuard(m_aMutex);
-       ::connectivity::checkDisposed(OColumnBase::rBHelper.bDisposed);
+       ::connectivity::checkDisposed(!m_xRow.is());
 
        return m_xRow->getArray(m_nPos);
 }
@@ -339,7 +338,7 @@
 void ODataColumn::updateNull(void) throw( SQLException, RuntimeException )
 {
        MutexGuard aGuard( m_aMutex );
-       ::connectivity::checkDisposed(OColumnBase::rBHelper.bDisposed);
+       ::connectivity::checkDisposed(!m_xRowUpdate.is());
 
        m_xRowUpdate->updateNull(m_nPos);
 }
@@ -348,7 +347,7 @@
 void ODataColumn::updateBoolean(sal_Bool x) throw( SQLException, 
RuntimeException )
 {
        MutexGuard aGuard( m_aMutex );
-       ::connectivity::checkDisposed(OColumnBase::rBHelper.bDisposed);
+       ::connectivity::checkDisposed(!m_xRowUpdate.is());
 
        m_xRowUpdate->updateBoolean(m_nPos, x);
 }
@@ -357,7 +356,7 @@
 void ODataColumn::updateByte(sal_Int8 x) throw( SQLException, RuntimeException 
)
 {
        MutexGuard aGuard( m_aMutex );
-       ::connectivity::checkDisposed(OColumnBase::rBHelper.bDisposed);
+       ::connectivity::checkDisposed(!m_xRowUpdate.is());
 
        m_xRowUpdate->updateByte(m_nPos, x);
 }
@@ -366,7 +365,7 @@
 void ODataColumn::updateShort(sal_Int16 x) throw( SQLException, 
RuntimeException )
 {
        MutexGuard aGuard( m_aMutex );
-       ::connectivity::checkDisposed(OColumnBase::rBHelper.bDisposed);
+       ::connectivity::checkDisposed(!m_xRowUpdate.is());
 
        m_xRowUpdate->updateShort(m_nPos, x);
 }
@@ -375,7 +374,7 @@
 void ODataColumn::updateInt(sal_Int32 x) throw( SQLException, RuntimeException 
)
 {
        MutexGuard aGuard( m_aMutex );
-       ::connectivity::checkDisposed(OColumnBase::rBHelper.bDisposed);
+       ::connectivity::checkDisposed(!m_xRowUpdate.is());
 
        m_xRowUpdate->updateInt(m_nPos, x);
 }
@@ -384,7 +383,7 @@
 void ODataColumn::updateLong(sal_Int64 x) throw( SQLException, 
RuntimeException )
 {
        MutexGuard aGuard( m_aMutex );
-       ::connectivity::checkDisposed(OColumnBase::rBHelper.bDisposed);
+       ::connectivity::checkDisposed(!m_xRowUpdate.is());
 
        m_xRowUpdate->updateLong(m_nPos, x);
 }
@@ -393,7 +392,7 @@
 void ODataColumn::updateFloat(float x) throw( SQLException, RuntimeException )
 {
        MutexGuard aGuard( m_aMutex );
-       ::connectivity::checkDisposed(OColumnBase::rBHelper.bDisposed);
+       ::connectivity::checkDisposed(!m_xRowUpdate.is());
 
        m_xRowUpdate->updateFloat(m_nPos, x);
 }
@@ -402,7 +401,7 @@
 void ODataColumn::updateDouble(double x) throw( SQLException, RuntimeException 
)
 {
        MutexGuard aGuard( m_aMutex );
-       ::connectivity::checkDisposed(OColumnBase::rBHelper.bDisposed);
+       ::connectivity::checkDisposed(!m_xRowUpdate.is());
 
        m_xRowUpdate->updateDouble(m_nPos, x);
 }
@@ -411,7 +410,7 @@
 void ODataColumn::updateString(const rtl::OUString& x) throw( SQLException, 
RuntimeException )
 {
        MutexGuard aGuard( m_aMutex );
-       ::connectivity::checkDisposed(OColumnBase::rBHelper.bDisposed);
+       ::connectivity::checkDisposed(!m_xRowUpdate.is());
 
        m_xRowUpdate->updateString(m_nPos, x);
 }
@@ -420,7 +419,7 @@
 void ODataColumn::updateBytes(const Sequence< sal_Int8 >& x) throw( 
SQLException, RuntimeException )
 {
        MutexGuard aGuard( m_aMutex );
-       ::connectivity::checkDisposed(OColumnBase::rBHelper.bDisposed);
+       ::connectivity::checkDisposed(!m_xRowUpdate.is());
 
        m_xRowUpdate->updateBytes(m_nPos, x);
 }
@@ -429,7 +428,7 @@
 void ODataColumn::updateDate(const com::sun::star::util::Date& x) throw( 
SQLException, RuntimeException )
 {
        MutexGuard aGuard( m_aMutex );
-       ::connectivity::checkDisposed(OColumnBase::rBHelper.bDisposed);
+       ::connectivity::checkDisposed(!m_xRowUpdate.is());
 
        m_xRowUpdate->updateDate(m_nPos, x);
 }
@@ -438,7 +437,7 @@
 void ODataColumn::updateTime(const ::com::sun::star::util::Time& x) throw( 
SQLException, RuntimeException )
 {
        MutexGuard aGuard( m_aMutex );
-       ::connectivity::checkDisposed(OColumnBase::rBHelper.bDisposed);
+       ::connectivity::checkDisposed(!m_xRowUpdate.is());
 
        m_xRowUpdate->updateTime(m_nPos, x);
 }
@@ -447,7 +446,7 @@
 void ODataColumn::updateTimestamp(const ::com::sun::star::util::DateTime& x) 
throw( SQLException, RuntimeException )
 {
        MutexGuard aGuard( m_aMutex );
-       ::connectivity::checkDisposed(OColumnBase::rBHelper.bDisposed);
+       ::connectivity::checkDisposed(!m_xRowUpdate.is());
 
        m_xRowUpdate->updateTimestamp(m_nPos, x);
 }
@@ -456,7 +455,7 @@
 void ODataColumn::updateCharacterStream(const Reference< 
::com::sun::star::io::XInputStream > & x, sal_Int32 length) throw( 
SQLException, RuntimeException )
 {
        MutexGuard aGuard( m_aMutex );
-       ::connectivity::checkDisposed(OColumnBase::rBHelper.bDisposed);
+       ::connectivity::checkDisposed(!m_xRowUpdate.is());
 
        m_xRowUpdate->updateCharacterStream(m_nPos, x, length);
 }
@@ -465,7 +464,7 @@
 void ODataColumn::updateBinaryStream(const Reference< 
::com::sun::star::io::XInputStream > & x, sal_Int32 length) throw( 
SQLException, RuntimeException )
 {
        MutexGuard aGuard( m_aMutex );
-       ::connectivity::checkDisposed(OColumnBase::rBHelper.bDisposed);
+       ::connectivity::checkDisposed(!m_xRowUpdate.is());
 
        m_xRowUpdate->updateBinaryStream(m_nPos, x, length);
 }
@@ -474,7 +473,7 @@
 void ODataColumn::updateNumericObject(const Any& x, sal_Int32 scale) throw( 
SQLException, RuntimeException )
 {
        MutexGuard aGuard( m_aMutex );
-       ::connectivity::checkDisposed(OColumnBase::rBHelper.bDisposed);
+       ::connectivity::checkDisposed(!m_xRowUpdate.is());
 
        m_xRowUpdate->updateNumericObject(m_nPos, x, scale);
 }
@@ -483,7 +482,7 @@
 void ODataColumn::updateObject(const Any& x) throw( SQLException, 
RuntimeException )
 {
        MutexGuard aGuard( m_aMutex );
-       ::connectivity::checkDisposed(OColumnBase::rBHelper.bDisposed);
+       ::connectivity::checkDisposed(!m_xRowUpdate.is());
        
        m_xRowUpdate->updateObject(m_nPos, x);
 }




---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to