Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
core
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
LibreOffice
core
Commits
dd995cea
Kaydet (Commit)
dd995cea
authored
Ock 19, 2011
tarafından
Michael Stahl
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
xmlfix3: #i113682#: unoxml: use CDocument mutex in misc classes
üst
12de6d54
Hide whitespace changes
Inline
Side-by-side
Showing
14 changed files
with
62 additions
and
17 deletions
+62
-17
attributesmap.cxx
unoxml/source/dom/attributesmap.cxx
+15
-1
attributesmap.hxx
unoxml/source/dom/attributesmap.hxx
+3
-1
childlist.cxx
unoxml/source/dom/childlist.cxx
+7
-1
childlist.hxx
unoxml/source/dom/childlist.hxx
+3
-1
document.cxx
unoxml/source/dom/document.cxx
+3
-3
documenttype.cxx
unoxml/source/dom/documenttype.cxx
+2
-2
element.cxx
unoxml/source/dom/element.cxx
+5
-3
elementlist.cxx
unoxml/source/dom/elementlist.cxx
+9
-0
elementlist.hxx
unoxml/source/dom/elementlist.hxx
+2
-0
entitiesmap.cxx
unoxml/source/dom/entitiesmap.cxx
+3
-1
entitiesmap.hxx
unoxml/source/dom/entitiesmap.hxx
+3
-1
node.cxx
unoxml/source/dom/node.cxx
+1
-1
notationsmap.cxx
unoxml/source/dom/notationsmap.cxx
+3
-1
notationsmap.hxx
unoxml/source/dom/notationsmap.hxx
+3
-1
No files found.
unoxml/source/dom/attributesmap.cxx
Dosyayı görüntüle @
dd995cea
...
...
@@ -35,8 +35,10 @@
namespace
DOM
{
CAttributesMap
::
CAttributesMap
(
::
rtl
::
Reference
<
CElement
>
const
&
pElement
)
CAttributesMap
::
CAttributesMap
(
::
rtl
::
Reference
<
CElement
>
const
&
pElement
,
::
osl
::
Mutex
&
rMutex
)
:
m_pElement
(
pElement
)
,
m_rMutex
(
rMutex
)
{
}
...
...
@@ -45,6 +47,8 @@ namespace DOM
*/
sal_Int32
SAL_CALL
CAttributesMap
::
getLength
()
throw
(
RuntimeException
)
{
::
osl
::
MutexGuard
const
g
(
m_rMutex
);
sal_Int32
count
=
0
;
xmlNodePtr
pNode
=
m_pElement
->
m_aNodePtr
;
if
(
pNode
!=
NULL
)
...
...
@@ -65,6 +69,8 @@ namespace DOM
Reference
<
XNode
>
SAL_CALL
CAttributesMap
::
getNamedItem
(
OUString
const
&
name
)
throw
(
RuntimeException
)
{
::
osl
::
MutexGuard
const
g
(
m_rMutex
);
Reference
<
XNode
>
aNode
;
xmlNodePtr
pNode
=
m_pElement
->
m_aNodePtr
;
if
(
pNode
!=
NULL
)
...
...
@@ -95,6 +101,8 @@ namespace DOM
OUString
const
&
namespaceURI
,
OUString
const
&
localName
)
throw
(
RuntimeException
)
{
::
osl
::
MutexGuard
const
g
(
m_rMutex
);
Reference
<
XNode
>
aNode
;
xmlNodePtr
pNode
=
m_pElement
->
m_aNodePtr
;
if
(
pNode
!=
NULL
)
...
...
@@ -127,6 +135,8 @@ namespace DOM
Reference
<
XNode
>
SAL_CALL
CAttributesMap
::
item
(
sal_Int32
index
)
throw
(
RuntimeException
)
{
::
osl
::
MutexGuard
const
g
(
m_rMutex
);
Reference
<
XNode
>
aNode
;
xmlNodePtr
pNode
=
m_pElement
->
m_aNodePtr
;
if
(
pNode
!=
NULL
)
...
...
@@ -156,6 +166,8 @@ namespace DOM
CAttributesMap
::
removeNamedItem
(
OUString
const
&
name
)
throw
(
RuntimeException
)
{
::
osl
::
MutexGuard
const
g
(
m_rMutex
);
xmlNodePtr
const
pNode
=
m_pElement
->
m_aNodePtr
;
if
(
pNode
!=
NULL
)
{
...
...
@@ -187,6 +199,8 @@ namespace DOM
OUString
const
&
namespaceURI
,
OUString
const
&
localName
)
throw
(
RuntimeException
)
{
::
osl
::
MutexGuard
const
g
(
m_rMutex
);
xmlNodePtr
const
pNode
=
m_pElement
->
m_aNodePtr
;
if
(
pNode
!=
NULL
)
{
...
...
unoxml/source/dom/attributesmap.hxx
Dosyayı görüntüle @
dd995cea
...
...
@@ -51,9 +51,11 @@ namespace DOM
{
private
:
::
rtl
::
Reference
<
CElement
>
const
m_pElement
;
::
osl
::
Mutex
&
m_rMutex
;
public
:
CAttributesMap
(
::
rtl
::
Reference
<
CElement
>
const
&
pElement
);
CAttributesMap
(
::
rtl
::
Reference
<
CElement
>
const
&
pElement
,
::
osl
::
Mutex
&
rMutex
);
/**
The number of nodes in this map.
...
...
unoxml/source/dom/childlist.cxx
Dosyayı görüntüle @
dd995cea
...
...
@@ -35,8 +35,10 @@
namespace
DOM
{
CChildList
::
CChildList
(
::
rtl
::
Reference
<
CNode
>
const
&
pBase
)
CChildList
::
CChildList
(
::
rtl
::
Reference
<
CNode
>
const
&
pBase
,
::
osl
::
Mutex
&
rMutex
)
:
m_pNode
(
pBase
)
,
m_rMutex
(
rMutex
)
{
}
...
...
@@ -45,6 +47,8 @@ namespace DOM
*/
sal_Int32
SAL_CALL
CChildList
::
getLength
()
throw
(
RuntimeException
)
{
::
osl
::
MutexGuard
const
g
(
m_rMutex
);
sal_Int32
length
=
0
;
if
(
m_pNode
!=
NULL
)
{
...
...
@@ -67,6 +71,8 @@ namespace DOM
Reference
<
XNode
>
SAL_CALL
CChildList
::
item
(
sal_Int32
index
)
throw
(
RuntimeException
)
{
::
osl
::
MutexGuard
const
g
(
m_rMutex
);
if
(
m_pNode
!=
NULL
)
{
xmlNodePtr
cur
=
m_pNode
->
m_aNodePtr
;
...
...
unoxml/source/dom/childlist.hxx
Dosyayı görüntüle @
dd995cea
...
...
@@ -51,9 +51,11 @@ namespace DOM
{
private
:
::
rtl
::
Reference
<
CNode
>
const
m_pNode
;
::
osl
::
Mutex
&
m_rMutex
;
public
:
CChildList
(
::
rtl
::
Reference
<
CNode
>
const
&
pBase
);
CChildList
(
::
rtl
::
Reference
<
CNode
>
const
&
pBase
,
::
osl
::
Mutex
&
rMutex
);
/**
The number of nodes in the list.
...
...
unoxml/source/dom/document.cxx
Dosyayı görüntüle @
dd995cea
...
...
@@ -686,7 +686,7 @@ namespace DOM
::
osl
::
MutexGuard
const
g
(
m_Mutex
);
Reference
<
XNodeList
>
const
xRet
(
new
CElementList
(
this
->
GetDocumentElement
(),
rTagname
));
new
CElementList
(
this
->
GetDocumentElement
(),
m_Mutex
,
rTagname
));
return
xRet
;
}
...
...
@@ -697,8 +697,8 @@ namespace DOM
::
osl
::
MutexGuard
const
g
(
m_Mutex
);
Reference
<
XNodeList
>
const
xRet
(
new
CElementList
(
this
->
GetDocumentElement
(),
rLocalName
,
&
rNamespaceURI
));
new
CElementList
(
this
->
GetDocumentElement
(),
m_Mutex
,
rLocalName
,
&
rNamespaceURI
));
return
xRet
;
}
...
...
unoxml/source/dom/documenttype.cxx
Dosyayı görüntüle @
dd995cea
...
...
@@ -56,7 +56,7 @@ namespace DOM
Reference
<
XNamedNodeMap
>
aMap
;
if
(
m_aDtdPtr
!=
NULL
)
{
aMap
=
Reference
<
XNamedNodeMap
>
(
new
CEntitiesMap
(
this
));
aMap
.
set
(
new
CEntitiesMap
(
this
,
m_rMutex
));
}
return
aMap
;
}
...
...
@@ -96,7 +96,7 @@ namespace DOM
Reference
<
XNamedNodeMap
>
aMap
;
if
(
m_aDtdPtr
!=
NULL
)
{
aMap
.
set
(
new
CNotationsMap
(
this
));
aMap
.
set
(
new
CNotationsMap
(
this
,
m_rMutex
));
}
return
aMap
;
}
...
...
unoxml/source/dom/element.cxx
Dosyayı görüntüle @
dd995cea
...
...
@@ -323,7 +323,8 @@ namespace DOM
{
::
osl
::
MutexGuard
const
g
(
m_rMutex
);
Reference
<
XNodeList
>
const
xList
(
new
CElementList
(
this
,
rLocalName
));
Reference
<
XNodeList
>
const
xList
(
new
CElementList
(
this
,
m_rMutex
,
rLocalName
));
return
xList
;
}
...
...
@@ -340,7 +341,7 @@ namespace DOM
::
osl
::
MutexGuard
const
g
(
m_rMutex
);
Reference
<
XNodeList
>
const
xList
(
new
CElementList
(
this
,
rLocalName
,
&
rNamespaceURI
));
new
CElementList
(
this
,
m_rMutex
,
rLocalName
,
&
rNamespaceURI
));
return
xList
;
}
...
...
@@ -693,7 +694,8 @@ namespace DOM
::
osl
::
MutexGuard
const
g
(
m_rMutex
);
if
(
!
hasAttributes
())
{
return
0
;
}
Reference
<
XNamedNodeMap
>
const
xMap
(
new
CAttributesMap
(
this
));
Reference
<
XNamedNodeMap
>
const
xMap
(
new
CAttributesMap
(
this
,
m_rMutex
));
return
xMap
;
}
...
...
unoxml/source/dom/elementlist.cxx
Dosyayı görüntüle @
dd995cea
...
...
@@ -46,8 +46,10 @@ namespace DOM
}
CElementList
::
CElementList
(
::
rtl
::
Reference
<
CElement
>
const
&
pElement
,
::
osl
::
Mutex
&
rMutex
,
OUString
const
&
rName
,
OUString
const
*
const
pURI
)
:
m_pElement
(
pElement
)
,
m_rMutex
(
rMutex
)
,
m_pName
(
lcl_initXmlString
(
rName
))
,
m_pURI
((
pURI
)
?
lcl_initXmlString
(
*
pURI
)
:
0
)
,
m_bRebuild
(
true
)
...
...
@@ -111,6 +113,8 @@ namespace DOM
*/
sal_Int32
SAL_CALL
CElementList
::
getLength
()
throw
(
RuntimeException
)
{
::
osl
::
MutexGuard
const
g
(
m_rMutex
);
// this has to be 'live'
buildlist
(
static_cast
<
const
CNode
*>
(
m_pElement
.
get
())
->
m_aNodePtr
);
return
m_nodevector
.
size
();
...
...
@@ -122,6 +126,9 @@ namespace DOM
throw
(
RuntimeException
)
{
if
(
index
<
0
)
throw
RuntimeException
();
::
osl
::
MutexGuard
const
g
(
m_rMutex
);
buildlist
(
static_cast
<
const
CNode
*>
(
m_pElement
.
get
())
->
m_aNodePtr
);
if
(
m_nodevector
.
size
()
<=
static_cast
<
size_t
>
(
index
))
{
throw
RuntimeException
();
...
...
@@ -135,6 +142,8 @@ namespace DOM
void
SAL_CALL
CElementList
::
handleEvent
(
Reference
<
XEvent
>
const
&
)
throw
(
RuntimeException
)
{
::
osl
::
MutexGuard
const
g
(
m_rMutex
);
m_bRebuild
=
true
;
}
}
unoxml/source/dom/elementlist.hxx
Dosyayı görüntüle @
dd995cea
...
...
@@ -64,6 +64,7 @@ namespace DOM
{
private
:
::
rtl
::
Reference
<
CElement
>
const
m_pElement
;
::
osl
::
Mutex
&
m_rMutex
;
::
boost
::
scoped_array
<
xmlChar
>
const
m_pName
;
::
boost
::
scoped_array
<
xmlChar
>
const
m_pURI
;
bool
m_bRebuild
;
...
...
@@ -74,6 +75,7 @@ namespace DOM
public
:
CElementList
(
::
rtl
::
Reference
<
CElement
>
const
&
pElement
,
::
osl
::
Mutex
&
rMutex
,
OUString
const
&
rName
,
OUString
const
*
const
pURI
=
0
);
/**
...
...
unoxml/source/dom/entitiesmap.cxx
Dosyayı görüntüle @
dd995cea
...
...
@@ -32,8 +32,10 @@
namespace
DOM
{
CEntitiesMap
::
CEntitiesMap
(
::
rtl
::
Reference
<
CDocumentType
>
const
&
pDocType
)
CEntitiesMap
::
CEntitiesMap
(
::
rtl
::
Reference
<
CDocumentType
>
const
&
pDocType
,
::
osl
::
Mutex
&
rMutex
)
:
m_pDocType
(
pDocType
)
,
m_rMutex
(
rMutex
)
{
}
...
...
unoxml/source/dom/entitiesmap.hxx
Dosyayı görüntüle @
dd995cea
...
...
@@ -51,9 +51,11 @@ namespace DOM
{
private
:
::
rtl
::
Reference
<
CDocumentType
>
const
m_pDocType
;
::
osl
::
Mutex
&
m_rMutex
;
public
:
CEntitiesMap
(
::
rtl
::
Reference
<
CDocumentType
>
const
&
pDocType
);
CEntitiesMap
(
::
rtl
::
Reference
<
CDocumentType
>
const
&
pDocType
,
::
osl
::
Mutex
&
rMutex
);
/**
The number of nodes in this map.
...
...
unoxml/source/dom/node.cxx
Dosyayı görüntüle @
dd995cea
...
...
@@ -452,7 +452,7 @@ namespace DOM
if
(
0
==
m_aNodePtr
)
{
return
0
;
}
Reference
<
XNodeList
>
const
xNodeList
(
new
CChildList
(
this
));
Reference
<
XNodeList
>
const
xNodeList
(
new
CChildList
(
this
,
m_rMutex
));
return
xNodeList
;
}
...
...
unoxml/source/dom/notationsmap.cxx
Dosyayı görüntüle @
dd995cea
...
...
@@ -33,8 +33,10 @@
namespace
DOM
{
CNotationsMap
::
CNotationsMap
(
::
rtl
::
Reference
<
CDocumentType
>
const
&
pDocType
)
::
rtl
::
Reference
<
CDocumentType
>
const
&
pDocType
,
::
osl
::
Mutex
&
rMutex
)
:
m_pDocType
(
pDocType
)
,
m_rMutex
(
rMutex
)
{
}
...
...
unoxml/source/dom/notationsmap.hxx
Dosyayı görüntüle @
dd995cea
...
...
@@ -51,9 +51,11 @@ namespace DOM
{
private
:
::
rtl
::
Reference
<
CDocumentType
>
const
m_pDocType
;
::
osl
::
Mutex
&
m_rMutex
;
public
:
CNotationsMap
(
::
rtl
::
Reference
<
CDocumentType
>
const
&
pDocType
);
CNotationsMap
(
::
rtl
::
Reference
<
CDocumentType
>
const
&
pDocType
,
::
osl
::
Mutex
&
rMutex
);
/**
The number of nodes in this map.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment