Tag: cws_src680_dba204c
User: fs      
Date: 2006/07/24 05:21:35

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

Log:
 #i67453# when extending an error message, caught during execution, with own 
information, don't allow for secondary exceptions to slip to the caller

File Changes:

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

File [changed]: RowSet.cxx
Url: 
http://dba.openoffice.org/source/browse/dba/dbaccess/source/core/api/RowSet.cxx?r1=1.145.8.1&r2=1.145.8.2
Delta lines:  +11 -4
--------------------
--- RowSet.cxx  21 Jul 2006 08:45:50 -0000      1.145.8.1
+++ RowSet.cxx  24 Jul 2006 12:21:32 -0000      1.145.8.2
@@ -4,9 +4,9 @@
  *
  *  $RCSfile: RowSet.cxx,v $
  *
- *  $Revision: 1.145.8.1 $
+ *  $Revision: 1.145.8.2 $
  *
- *  last change: $Author: fs $ $Date: 2006/07/21 08:45:50 $
+ *  last change: $Author: fs $ $Date: 2006/07/24 12:21:32 $
  *
  *  The Contents of this file are made available subject to
  *  the terms of GNU Lesser General Public License Version 2.1.
@@ -1693,9 +1693,16 @@
         SQLExceptionInfo aError( ::cppu::getCaughtException() );
         OSL_ENSURE( aError.isValid(), "ORowSet::execute_NoApprove_NoNewConn: 
caught an SQLException which we cannot analyze!" );
 
-        String sInfo( DBA_RES_PARAM( RID_STR_COMMAND_LEADING_TO_ERROR, 
"$command$", impl_getComposedQuery_throw( false ) ) );
+        // append information about what we were actually going to execute
+        try
+        {
+            String sQuery = bUseEscapeProcessing ? 
impl_getComposedQuery_throw( false ) : m_aActiveCommand;
+            String sInfo( DBA_RES_PARAM( RID_STR_COMMAND_LEADING_TO_ERROR, 
"$command$", sQuery ) );
         aError.append( SQLExceptionInfo::SQL_CONTEXT, sInfo );
+        }
+        catch( const Exception& ) { DBG_UNHANDLED_EXCEPTION(); }
 
+        // propagate
         aError.doThrow();
     }
 




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

Reply via email to