Date: prev next · Thread: first prev next last
2011 Archives by date, by thread · List index


Hi,

I just wonder if a mutex guard should protect the whole body of
SmGraphicAccessible::setCaretPosition() in starmath/source/accessibility.cxx
as attached.
Any suggestion will be appreciated.

Cheers,
-- Takeshi Abe
From 21c238a3a88b65aa1a74574a76784c83caf4dc41 Mon Sep 17 00:00:00 2001
From: Takeshi Abe <tabe@fixedpoint.jp>
Date: Thu, 7 Apr 2011 21:24:23 +0900
Subject: [PATCH] guarded by mutex

---
 starmath/source/accessibility.cxx |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/starmath/source/accessibility.cxx b/starmath/source/accessibility.cxx
index 8f38950..8a885f6 100644
--- a/starmath/source/accessibility.cxx
+++ b/starmath/source/accessibility.cxx
@@ -462,6 +462,7 @@ sal_Int32 SAL_CALL SmGraphicAccessible::getCaretPosition()
 sal_Bool SAL_CALL SmGraphicAccessible::setCaretPosition( sal_Int32 nIndex )
     throw (IndexOutOfBoundsException, RuntimeException)
 {
+    SolarMutexGuard aGuard;
     xub_StrLen nIdx = (xub_StrLen) nIndex;
     String aTxt( GetAccessibleText_Impl() );
     if (!(nIdx < aTxt.Len()))
-- 
1.7.2.5


Context


Privacy Policy | Impressum (Legal Info) | Copyright information: Unless otherwise specified, all text and images on this website are licensed under the Creative Commons Attribution-Share Alike 3.0 License. This does not include the source code of LibreOffice, which is licensed under the Mozilla Public License (MPLv2). "LibreOffice" and "The Document Foundation" are registered trademarks of their corresponding registered owners or are in actual use as trademarks in one or more countries. Their respective logos and icons are also subject to international copyright laws. Use thereof is explained in our trademark policy.