[Libreoffice-bugs] [Bug 107458] Crash when just displaying LibreLogo and click >> ( accessibility/gtk/gtk3)
bugzilla-daemon at bugs.documentfoundation.org
bugzilla-daemon at bugs.documentfoundation.org
Wed Apr 26 20:27:53 UTC 2017
https://bugs.documentfoundation.org/show_bug.cgi?id=107458
--- Comment #2 from Julien Nabet <serval2412 at yahoo.fr> ---
I thought about this straightforward patch:
diff --git a/accessibility/source/standard/vclxaccessibletoolbox.cxx
b/accessibility/source/standard/vclxaccessibletoolbox.cxx
index aa4cad63acb8..55ab3e7a0899 100644
--- a/accessibility/source/standard/vclxaccessibletoolbox.cxx
+++ b/accessibility/source/standard/vclxaccessibletoolbox.cxx
@@ -461,8 +461,10 @@ void VCLXAccessibleToolBox::HandleSubToolBarEvent( const
VclWindowEvent& rVclWin
&& pToolBox == pChildWindow->GetParent()
&& pChildWindow->GetType() == WindowType::TOOLBOX )
{
- ToolBox::ImplToolItems::size_type nIndex = pToolBox->GetItemPos(
pToolBox->GetCurItemId() );
- Reference< XAccessible > xItem = getAccessibleChild( nIndex );
+ sal_Int32 nIndex = static_cast<sal_Int32>(pToolBox->GetItemPos(
pToolBox->GetCurItemId() ));
+ if (nIndex < 0)
+ return;
+ Reference< XAccessible > xItem = getAccessibleChild(nIndex);
//TODO: ToolBox::ImplToolItems::size_type -> sal_Int32!
if ( xItem.is() )
{
What do you think?
--
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/libreoffice-bugs/attachments/20170426/8dac8b9b/attachment.html>
More information about the Libreoffice-bugs
mailing list