svx/source/tbxctrls/tbcontrl.cxx |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 9a3ccbb69c9b4f2fb046d26d588fbe2521c99a52
Author: Szymon Kłos <eszka...@gmail.com>
Date:   Fri Oct 3 18:59:19 2014 +0200

    fdo#84620 : The styles drop down menu in Writer crashes LO.
    
    Change-Id: I4fe52a1c9aabae1ad09dd94b75c3605dcb023d42
    Reviewed-on: https://gerrit.libreoffice.org/11796
    Reviewed-by: Samuel Mehrbrodt <s.mehrbr...@gmail.com>
    Tested-by: Samuel Mehrbrodt <s.mehrbr...@gmail.com>

diff --git a/svx/source/tbxctrls/tbcontrl.cxx b/svx/source/tbxctrls/tbcontrl.cxx
index 193d9ad..f9bcf18 100644
--- a/svx/source/tbxctrls/tbcontrl.cxx
+++ b/svx/source/tbxctrls/tbcontrl.cxx
@@ -557,7 +557,7 @@ void SvxStyleBox_Impl::UserDraw( const UserDrawEvent& 
rUDEvt )
     {
         Rectangle aRect(rUDEvt.GetRect());
         unsigned int nId = (aRect.getY() / aRect.GetSize().Height());
-        if(m_pButtons[nId])
+        if(nId < MAX_STYLES_ENTRIES && m_pButtons[nId])
             m_pButtons[nId]->Hide();
         // draw the non-style entries, ie. "Clear Formatting" or "More..."
         DrawEntry( rUDEvt, true, true );
_______________________________________________
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to