ooo-build r12690 - in branches/ooo-build-2-4-1: . patches/src680



Author: pmladek
Date: Wed May 28 17:35:19 2008
New Revision: 12690
URL: http://svn.gnome.org/viewvc/ooo-build?rev=12690&view=rev

Log:
2008-05-28  Petr Mladek  <pmladek suse cz>

	* patches/src680/cws-dba241e.diff, patches/src680/apply: two
	  upstream blocker bug fixes; will be integrated in ooh680-m17;
	  (i#87092, i#90011)



Added:
   branches/ooo-build-2-4-1/patches/src680/cws-dba241e.diff
Modified:
   branches/ooo-build-2-4-1/ChangeLog
   branches/ooo-build-2-4-1/patches/src680/apply

Modified: branches/ooo-build-2-4-1/patches/src680/apply
==============================================================================
--- branches/ooo-build-2-4-1/patches/src680/apply	(original)
+++ branches/ooo-build-2-4-1/patches/src680/apply	Wed May 28 17:35:19 2008
@@ -320,6 +320,10 @@
 
 cws-hsqldb16.diff, i#85087
 
+[ CWSBackports < ooh680-m17 ]
+
+cws-dba241e.diff, i#87092, i#90011
+
 
 [ WPG ]
 # libwpg-based import filter for WordPerfect Graphics

Added: branches/ooo-build-2-4-1/patches/src680/cws-dba241e.diff
==============================================================================
--- (empty file)
+++ branches/ooo-build-2-4-1/patches/src680/cws-dba241e.diff	Wed May 28 17:35:19 2008
@@ -0,0 +1,70 @@
+Index: sw/source/core/crsr/findtxt.cxx
+===================================================================
+RCS file: /cvs/sw/sw/source/core/crsr/findtxt.cxx,v
+retrieving revision 1.22
+retrieving revision 1.22.24.1
+diff -u -p -u -p -b -w -B -r1.22 -r1.22.24.1
+--- sw/source/core/crsr/findtxt.cxx	5 Dec 2007 16:43:55 -0000	1.22
++++ sw/source/core/crsr/findtxt.cxx	27 May 2008 21:14:30 -0000	1.22.24.1
+@@ -548,11 +548,17 @@ String *ReplaceBackReferences( const Sea
+                 ++nStart;
+             }
+             xub_StrLen nEnd = aStr.Len();
++            bool bDeleteLastX = false;
+             if( pPam->End()->nContent < (static_cast<const SwTxtNode*>(pTxtNode))->GetTxt().Len() )
++            {
+                 aStr.Insert( sX );
++                bDeleteLastX = true;
++            }
+             SearchResult aResult;
+             if( aSTxt.SearchFrwrd( aStr, &nStart, &nEnd, &aResult ) )
+             {
++                if( bDeleteLastX && aStr.Len() )
++                    aStr.Erase( aStr.Len() - 1 );
+                 aSTxt.ReplaceBackReferences( aReplaceStr, aStr, aResult );
+                 pRet = new String( aReplaceStr );
+             }
+Index: dbaccess/source/core/dataaccess/ModelImpl.cxx
+===================================================================
+RCS file: /cvs/dba/dbaccess/source/core/dataaccess/ModelImpl.cxx,v
+retrieving revision 1.21.18.5
+retrieving revision 1.21.18.5.2.1
+diff -u -p -u -p -b -w -B -r1.21.18.5 -r1.21.18.5.2.1
+--- dbaccess/source/core/dataaccess/ModelImpl.cxx	20 May 2008 18:22:49 -0000	1.21.18.5
++++ dbaccess/source/core/dataaccess/ModelImpl.cxx	27 May 2008 21:09:23 -0000	1.21.18.5.2.1
+@@ -456,7 +456,7 @@ namespace
+     }
+ 
+     // .........................................................................
+-    bool lcl_hasObjectWithMacros_throw( const ODefinitionContainer_Impl& _rObjectDefinitions, const ::utl::SharedUNOComponent< XStorage >& _rxContainerStorage )
++    bool lcl_hasObjectWithMacros_throw( const ODefinitionContainer_Impl& _rObjectDefinitions, const Reference< XStorage >& _rxContainerStorage )
+     {
+         bool bSomeDocHasMacros = false;
+ 
+@@ -479,7 +479,7 @@ namespace
+                 continue;
+             }
+ 
+-            ::utl::SharedUNOComponent< XStorage > xObjectStor( _rxContainerStorage->openStorageElement(
++            Reference< XStorage > xObjectStor( _rxContainerStorage->openStorageElement(
+                 rPersistentName, ElementModes::READ ) );
+ 
+             // TODO: opening the storage is too expensive, find some hasByHierarchicalName or so
+@@ -499,8 +499,15 @@ namespace
+ 
+         try
+         {
+-            ::utl::SharedUNOComponent< XStorage > xContainerStorage( _rModel.getStorage(
+-                _rModel.getObjectContainerStorageName( _eType ), ElementModes::READ ) );
++            Reference< XStorage > xContainerStorage( _rModel.getStorage(
++                _rModel.getObjectContainerStorageName( _eType ), ElementModes::READWRITE ) );
++            // note the READWRITE here: If the storage already existed before, then the OpenMode will
++            // be ignored, anyway.
++            // If the storage did not yet exist, then it will be created. If the database document
++            // is read-only, the OpenMode will be automatically downgraded to READ. Otherwise,
++            // the storage will in fact be created as READWRITE. While this is not strictly necessary
++            // for this particular use case here, it is required since the storage is *cached*, and
++            // later use cases will need the READWRITE mode.
+   
+             if ( xContainerStorage.is() )
+                 bSomeDocHasMacros = lcl_hasObjectWithMacros_throw( rObjectDefinitions, xContainerStorage );



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]