[ooo-build-commit] .: patches/dev300

Thorsten Behrens thorsten at kemper.freedesktop.org
Tue Jan 26 11:20:08 PST 2010


 patches/dev300/apply                       |    2 
 patches/dev300/cws-sb118-headless-fix.diff |   60 +++++++++++++++++++++++++++++
 2 files changed, 62 insertions(+)

New commits:
commit f905c12a1ef17ff35ad60dde4a08daf61b85aa26
Author: Thorsten Behrens <tbehrens at novell.com>
Date:   Tue Jan 26 20:16:19 2010 +0100

    Fix crash in headless mode
    
    * patches/dev300/apply: added patch
    * patches/dev300/cws-sb118-headless-fix.diff: backport from 3.3 -
      prevent crash in headless svp mode. fix courtesy pl. i#108681.

diff --git a/patches/dev300/apply b/patches/dev300/apply
index 31a41d4..8213e1e 100644
--- a/patches/dev300/apply
+++ b/patches/dev300/apply
@@ -3493,3 +3493,5 @@ evaluation-row-limit.diff
 # TODO: split up into the original patches were this belongs
 valgrind-fixes.diff, thorsten
 framework-menubar-fix.diff, thorsten
+# backport from 3.3 - prevent crash in headless svp mode
+cws-sb118-headless-fix.diff, i#108681, thorsten
diff --git a/patches/dev300/cws-sb118-headless-fix.diff b/patches/dev300/cws-sb118-headless-fix.diff
new file mode 100644
index 0000000..67e8bd6
--- /dev/null
+++ b/patches/dev300/cws-sb118-headless-fix.diff
@@ -0,0 +1,60 @@
+sb118: #i108681# hack by pl to not process events for removed frames
+
+diff -r 3a83f951e8d2 -r 8b08e64b518c vcl/unx/headless/svpinst.cxx
+--- vcl/unx/headless/svpinst.cxx	Mon Jan 25 11:43:22 2010 +0100
++++ vcl/unx/headless/svpinst.cxx	Tue Jan 26 16:53:19 2010 +0100
+@@ -58,6 +58,19 @@
+     }
+ }
+ 
++bool SvpSalInstance::isFrameAlive( const SalFrame* pFrame ) const
++{
++    for( std::list< SalFrame* >::const_iterator it = m_aFrames.begin();
++         it != m_aFrames.end(); ++it )
++    {
++        if( *it == pFrame )
++        {
++            return true;
++        }
++    }
++    return false;
++}
++
+ SvpSalInstance* SvpSalInstance::s_pDefaultInstance = NULL;
+ 
+ SvpSalInstance::SvpSalInstance()
+@@ -349,12 +362,15 @@
+     {
+         for( std::list<SalUserEvent>::const_iterator it = aEvents.begin(); it != aEvents.end(); ++it )
+         {
+-            it->m_pFrame->CallCallback( it->m_nEvent, it->m_pData );
+-            if( it->m_nEvent == SALEVENT_RESIZE )
++            if ( isFrameAlive( it->m_pFrame ) )
+             {
+-                // this would be a good time to post a paint
+-                const SvpSalFrame* pSvpFrame = static_cast<const SvpSalFrame*>(it->m_pFrame);
+-                pSvpFrame->PostPaint();
++                it->m_pFrame->CallCallback( it->m_nEvent, it->m_pData );
++                if( it->m_nEvent == SALEVENT_RESIZE )
++                {
++                    // this would be a good time to post a paint
++                    const SvpSalFrame* pSvpFrame = static_cast<const SvpSalFrame*>(it->m_pFrame);
++                    pSvpFrame->PostPaint();
++                }
+             }
+         }
+     }
+diff -r 3a83f951e8d2 -r 8b08e64b518c vcl/unx/headless/svpinst.hxx
+--- vcl/unx/headless/svpinst.hxx	Mon Jan 25 11:43:22 2010 +0100
++++ vcl/unx/headless/svpinst.hxx	Tue Jan 26 16:53:19 2010 +0100
+@@ -111,6 +111,9 @@
+     std::list< SalUserEvent > m_aUserEvents;
+     
+     std::list< SalFrame* > m_aFrames;
++
++    bool isFrameAlive( const SalFrame* pFrame ) const;
++
+ public:
+     static SvpSalInstance* s_pDefaultInstance;
+ 
+


More information about the ooo-build-commit mailing list