mirror of
https://gitlab.gnome.org/GNOME/libxml2.git
synced 2025-07-28 00:21:53 +03:00
backport of a thread bugfix from 2_5_X branch Daniel
* threads.c: backport of a thread bugfix from 2_5_X branch Daniel
This commit is contained in:
@ -1,3 +1,7 @@
|
|||||||
|
Fri Sep 12 01:34:19 CEST 2003 Daniel Veillard <daniel@veillard.com>
|
||||||
|
|
||||||
|
* threads.c: backport of a thread bugfix from 2_5_X branch
|
||||||
|
|
||||||
Thu Sep 11 18:29:18 CEST 2003 Daniel Veillard <daniel@veillard.com>
|
Thu Sep 11 18:29:18 CEST 2003 Daniel Veillard <daniel@veillard.com>
|
||||||
|
|
||||||
* parser.c: fixed a bug in one corner case of attribute parsing.
|
* parser.c: fixed a bug in one corner case of attribute parsing.
|
||||||
|
@ -573,41 +573,53 @@ Class xmlDoc(xmlNode)
|
|||||||
|
|
||||||
# functions from module xpointer
|
# functions from module xpointer
|
||||||
xpointerNewContext()
|
xpointerNewContext()
|
||||||
Class xpathContext()
|
|
||||||
# accessors
|
|
||||||
contextDoc()
|
|
||||||
contextNode()
|
|
||||||
contextPosition()
|
|
||||||
contextSize()
|
|
||||||
function()
|
|
||||||
functionURI()
|
|
||||||
setContextDoc()
|
|
||||||
setContextNode()
|
|
||||||
|
|
||||||
# functions from module python
|
|
||||||
registerXPathFunction()
|
|
||||||
|
|
||||||
# functions from module xpath
|
|
||||||
xpathEval()
|
|
||||||
xpathEvalExpression()
|
|
||||||
xpathFreeContext()
|
|
||||||
|
|
||||||
# functions from module xpathInternals
|
|
||||||
xpathNewParserContext()
|
|
||||||
xpathNsLookup()
|
|
||||||
xpathRegisterAllFunctions()
|
|
||||||
xpathRegisterNs()
|
|
||||||
xpathRegisteredFuncsCleanup()
|
|
||||||
xpathRegisteredNsCleanup()
|
|
||||||
xpathRegisteredVariablesCleanup()
|
|
||||||
xpathVariableLookup()
|
|
||||||
xpathVariableLookupNS()
|
|
||||||
|
|
||||||
# functions from module xpointer
|
|
||||||
xpointerEval()
|
|
||||||
|
|
||||||
|
|
||||||
Class xmlAttribute(xmlNode)
|
Class xmlAttribute(xmlNode)
|
||||||
|
Class xmlTextReaderLocator()
|
||||||
|
|
||||||
|
# functions from module xmlreader
|
||||||
|
BaseURI()
|
||||||
|
LineNumber()
|
||||||
|
|
||||||
|
|
||||||
|
Class xmlNs(xmlNode)
|
||||||
|
|
||||||
|
# functions from module tree
|
||||||
|
copyNamespace()
|
||||||
|
copyNamespaceList()
|
||||||
|
freeNs()
|
||||||
|
freeNsList()
|
||||||
|
newChild()
|
||||||
|
newDocNode()
|
||||||
|
newDocNodeEatName()
|
||||||
|
newDocRawNode()
|
||||||
|
newNodeEatName()
|
||||||
|
newNsProp()
|
||||||
|
newNsPropEatName()
|
||||||
|
newTextChild()
|
||||||
|
setNs()
|
||||||
|
setNsProp()
|
||||||
|
unsetNsProp()
|
||||||
|
|
||||||
|
# functions from module xpathInternals
|
||||||
|
xpathNodeSetFreeNs()
|
||||||
|
|
||||||
|
|
||||||
|
Class xmlDtd(xmlNode)
|
||||||
|
|
||||||
|
# functions from module debugXML
|
||||||
|
debugDumpDTD()
|
||||||
|
|
||||||
|
# functions from module tree
|
||||||
|
copyDtd()
|
||||||
|
freeDtd()
|
||||||
|
|
||||||
|
# functions from module valid
|
||||||
|
dtdAttrDesc()
|
||||||
|
dtdElementDesc()
|
||||||
|
dtdQAttrDesc()
|
||||||
|
dtdQElementDesc()
|
||||||
Class catalog()
|
Class catalog()
|
||||||
|
|
||||||
# functions from module catalog
|
# functions from module catalog
|
||||||
@ -621,106 +633,6 @@ Class catalog()
|
|||||||
resolvePublic()
|
resolvePublic()
|
||||||
resolveSystem()
|
resolveSystem()
|
||||||
resolveURI()
|
resolveURI()
|
||||||
|
|
||||||
|
|
||||||
Class xmlElement(xmlNode)
|
|
||||||
|
|
||||||
|
|
||||||
Class xmlAttr(xmlNode)
|
|
||||||
|
|
||||||
# functions from module debugXML
|
|
||||||
debugDumpAttr()
|
|
||||||
debugDumpAttrList()
|
|
||||||
|
|
||||||
# functions from module tree
|
|
||||||
copyProp()
|
|
||||||
copyPropList()
|
|
||||||
freeProp()
|
|
||||||
freePropList()
|
|
||||||
removeProp()
|
|
||||||
|
|
||||||
# functions from module valid
|
|
||||||
removeID()
|
|
||||||
removeRef()
|
|
||||||
|
|
||||||
|
|
||||||
Class xmlTextReader(xmlTextReaderCore)
|
|
||||||
|
|
||||||
# functions from module xmlreader
|
|
||||||
AttributeCount()
|
|
||||||
BaseUri()
|
|
||||||
Close()
|
|
||||||
CurrentDoc()
|
|
||||||
CurrentNode()
|
|
||||||
Depth()
|
|
||||||
Expand()
|
|
||||||
GetAttribute()
|
|
||||||
GetAttributeNo()
|
|
||||||
GetAttributeNs()
|
|
||||||
GetParserProp()
|
|
||||||
GetRemainder()
|
|
||||||
HasAttributes()
|
|
||||||
HasValue()
|
|
||||||
IsDefault()
|
|
||||||
IsEmptyElement()
|
|
||||||
IsValid()
|
|
||||||
LocalName()
|
|
||||||
LookupNamespace()
|
|
||||||
MoveToAttribute()
|
|
||||||
MoveToAttributeNo()
|
|
||||||
MoveToAttributeNs()
|
|
||||||
MoveToElement()
|
|
||||||
MoveToFirstAttribute()
|
|
||||||
MoveToNextAttribute()
|
|
||||||
Name()
|
|
||||||
NamespaceUri()
|
|
||||||
Next()
|
|
||||||
NodeType()
|
|
||||||
Normalization()
|
|
||||||
Prefix()
|
|
||||||
QuoteChar()
|
|
||||||
Read()
|
|
||||||
ReadAttributeValue()
|
|
||||||
ReadInnerXml()
|
|
||||||
ReadOuterXml()
|
|
||||||
ReadState()
|
|
||||||
ReadString()
|
|
||||||
RelaxNGSetSchema()
|
|
||||||
RelaxNGValidate()
|
|
||||||
SetParserProp()
|
|
||||||
Value()
|
|
||||||
XmlLang()
|
|
||||||
Class xmlReg()
|
|
||||||
|
|
||||||
# functions from module xmlregexp
|
|
||||||
regexpExec()
|
|
||||||
regexpFreeRegexp()
|
|
||||||
regexpIsDeterminist()
|
|
||||||
regexpPrint()
|
|
||||||
|
|
||||||
|
|
||||||
Class xmlEntity(xmlNode)
|
|
||||||
|
|
||||||
# functions from module parserInternals
|
|
||||||
handleEntity()
|
|
||||||
Class relaxNgSchema()
|
|
||||||
|
|
||||||
# functions from module relaxng
|
|
||||||
relaxNGDump()
|
|
||||||
relaxNGDumpTree()
|
|
||||||
relaxNGFree()
|
|
||||||
relaxNGNewValidCtxt()
|
|
||||||
|
|
||||||
# functions from module xmlreader
|
|
||||||
RelaxNGSetSchema()
|
|
||||||
Class relaxNgValidCtxt()
|
|
||||||
|
|
||||||
# functions from module relaxng
|
|
||||||
relaxNGValidateDoc()
|
|
||||||
relaxNGValidateFullElement()
|
|
||||||
relaxNGValidatePopElement()
|
|
||||||
relaxNGValidatePushCData()
|
|
||||||
relaxNGValidatePushElement()
|
|
||||||
Class xpathParserContext()
|
Class xpathParserContext()
|
||||||
# accessors
|
# accessors
|
||||||
context()
|
context()
|
||||||
@ -866,62 +778,6 @@ Class parserCtxt(parserCtxtCore)
|
|||||||
stringLenDecodeEntities()
|
stringLenDecodeEntities()
|
||||||
|
|
||||||
|
|
||||||
Class xmlDtd(xmlNode)
|
|
||||||
|
|
||||||
# functions from module debugXML
|
|
||||||
debugDumpDTD()
|
|
||||||
|
|
||||||
# functions from module tree
|
|
||||||
copyDtd()
|
|
||||||
freeDtd()
|
|
||||||
|
|
||||||
# functions from module valid
|
|
||||||
dtdAttrDesc()
|
|
||||||
dtdElementDesc()
|
|
||||||
dtdQAttrDesc()
|
|
||||||
dtdQElementDesc()
|
|
||||||
|
|
||||||
|
|
||||||
Class xmlNs(xmlNode)
|
|
||||||
|
|
||||||
# functions from module tree
|
|
||||||
copyNamespace()
|
|
||||||
copyNamespaceList()
|
|
||||||
freeNs()
|
|
||||||
freeNsList()
|
|
||||||
newChild()
|
|
||||||
newDocNode()
|
|
||||||
newDocNodeEatName()
|
|
||||||
newDocRawNode()
|
|
||||||
newNodeEatName()
|
|
||||||
newNsProp()
|
|
||||||
newNsPropEatName()
|
|
||||||
newTextChild()
|
|
||||||
setNs()
|
|
||||||
setNsProp()
|
|
||||||
unsetNsProp()
|
|
||||||
|
|
||||||
# functions from module xpathInternals
|
|
||||||
xpathNodeSetFreeNs()
|
|
||||||
|
|
||||||
|
|
||||||
Class inputBuffer(ioReadWrapper)
|
|
||||||
|
|
||||||
# functions from module xmlIO
|
|
||||||
freeParserInputBuffer()
|
|
||||||
grow()
|
|
||||||
push()
|
|
||||||
read()
|
|
||||||
|
|
||||||
# functions from module xmlreader
|
|
||||||
newTextReader()
|
|
||||||
Class relaxNgParserCtxt()
|
|
||||||
|
|
||||||
# functions from module relaxng
|
|
||||||
relaxNGFreeParserCtxt()
|
|
||||||
relaxNGParse()
|
|
||||||
|
|
||||||
|
|
||||||
Class outputBuffer(ioWriteWrapper)
|
Class outputBuffer(ioWriteWrapper)
|
||||||
|
|
||||||
# functions from module HTMLtree
|
# functions from module HTMLtree
|
||||||
@ -940,11 +796,98 @@ Class outputBuffer(ioWriteWrapper)
|
|||||||
flush()
|
flush()
|
||||||
write()
|
write()
|
||||||
writeString()
|
writeString()
|
||||||
Class xmlTextReaderLocator()
|
|
||||||
|
|
||||||
|
Class xmlElement(xmlNode)
|
||||||
|
Class relaxNgSchema()
|
||||||
|
|
||||||
|
# functions from module relaxng
|
||||||
|
relaxNGDump()
|
||||||
|
relaxNGDumpTree()
|
||||||
|
relaxNGFree()
|
||||||
|
relaxNGNewValidCtxt()
|
||||||
|
|
||||||
# functions from module xmlreader
|
# functions from module xmlreader
|
||||||
BaseURI()
|
RelaxNGSetSchema()
|
||||||
LineNumber()
|
|
||||||
|
|
||||||
|
Class xmlEntity(xmlNode)
|
||||||
|
|
||||||
|
# functions from module parserInternals
|
||||||
|
handleEntity()
|
||||||
|
|
||||||
|
|
||||||
|
Class xmlTextReader(xmlTextReaderCore)
|
||||||
|
|
||||||
|
# functions from module xmlreader
|
||||||
|
AttributeCount()
|
||||||
|
BaseUri()
|
||||||
|
Close()
|
||||||
|
CurrentDoc()
|
||||||
|
CurrentNode()
|
||||||
|
Depth()
|
||||||
|
Expand()
|
||||||
|
GetAttribute()
|
||||||
|
GetAttributeNo()
|
||||||
|
GetAttributeNs()
|
||||||
|
GetParserProp()
|
||||||
|
GetRemainder()
|
||||||
|
HasAttributes()
|
||||||
|
HasValue()
|
||||||
|
IsDefault()
|
||||||
|
IsEmptyElement()
|
||||||
|
IsValid()
|
||||||
|
LocalName()
|
||||||
|
LookupNamespace()
|
||||||
|
MoveToAttribute()
|
||||||
|
MoveToAttributeNo()
|
||||||
|
MoveToAttributeNs()
|
||||||
|
MoveToElement()
|
||||||
|
MoveToFirstAttribute()
|
||||||
|
MoveToNextAttribute()
|
||||||
|
Name()
|
||||||
|
NamespaceUri()
|
||||||
|
Next()
|
||||||
|
NodeType()
|
||||||
|
Normalization()
|
||||||
|
Prefix()
|
||||||
|
QuoteChar()
|
||||||
|
Read()
|
||||||
|
ReadAttributeValue()
|
||||||
|
ReadInnerXml()
|
||||||
|
ReadOuterXml()
|
||||||
|
ReadState()
|
||||||
|
ReadString()
|
||||||
|
RelaxNGSetSchema()
|
||||||
|
RelaxNGValidate()
|
||||||
|
SetParserProp()
|
||||||
|
Value()
|
||||||
|
XmlLang()
|
||||||
|
|
||||||
|
|
||||||
|
Class xmlAttr(xmlNode)
|
||||||
|
|
||||||
|
# functions from module debugXML
|
||||||
|
debugDumpAttr()
|
||||||
|
debugDumpAttrList()
|
||||||
|
|
||||||
|
# functions from module tree
|
||||||
|
copyProp()
|
||||||
|
copyPropList()
|
||||||
|
freeProp()
|
||||||
|
freePropList()
|
||||||
|
removeProp()
|
||||||
|
|
||||||
|
# functions from module valid
|
||||||
|
removeID()
|
||||||
|
removeRef()
|
||||||
|
Class xmlReg()
|
||||||
|
|
||||||
|
# functions from module xmlregexp
|
||||||
|
regexpExec()
|
||||||
|
regexpFreeRegexp()
|
||||||
|
regexpIsDeterminist()
|
||||||
|
regexpPrint()
|
||||||
Class URI()
|
Class URI()
|
||||||
# accessors
|
# accessors
|
||||||
authority()
|
authority()
|
||||||
@ -971,3 +914,60 @@ Class URI()
|
|||||||
parseURIReference()
|
parseURIReference()
|
||||||
printURI()
|
printURI()
|
||||||
saveUri()
|
saveUri()
|
||||||
|
Class relaxNgParserCtxt()
|
||||||
|
|
||||||
|
# functions from module relaxng
|
||||||
|
relaxNGFreeParserCtxt()
|
||||||
|
relaxNGParse()
|
||||||
|
Class xpathContext()
|
||||||
|
# accessors
|
||||||
|
contextDoc()
|
||||||
|
contextNode()
|
||||||
|
contextPosition()
|
||||||
|
contextSize()
|
||||||
|
function()
|
||||||
|
functionURI()
|
||||||
|
setContextDoc()
|
||||||
|
setContextNode()
|
||||||
|
|
||||||
|
# functions from module python
|
||||||
|
registerXPathFunction()
|
||||||
|
|
||||||
|
# functions from module xpath
|
||||||
|
xpathEval()
|
||||||
|
xpathEvalExpression()
|
||||||
|
xpathFreeContext()
|
||||||
|
|
||||||
|
# functions from module xpathInternals
|
||||||
|
xpathNewParserContext()
|
||||||
|
xpathNsLookup()
|
||||||
|
xpathRegisterAllFunctions()
|
||||||
|
xpathRegisterNs()
|
||||||
|
xpathRegisteredFuncsCleanup()
|
||||||
|
xpathRegisteredNsCleanup()
|
||||||
|
xpathRegisteredVariablesCleanup()
|
||||||
|
xpathVariableLookup()
|
||||||
|
xpathVariableLookupNS()
|
||||||
|
|
||||||
|
# functions from module xpointer
|
||||||
|
xpointerEval()
|
||||||
|
|
||||||
|
|
||||||
|
Class inputBuffer(ioReadWrapper)
|
||||||
|
|
||||||
|
# functions from module xmlIO
|
||||||
|
freeParserInputBuffer()
|
||||||
|
grow()
|
||||||
|
push()
|
||||||
|
read()
|
||||||
|
|
||||||
|
# functions from module xmlreader
|
||||||
|
newTextReader()
|
||||||
|
Class relaxNgValidCtxt()
|
||||||
|
|
||||||
|
# functions from module relaxng
|
||||||
|
relaxNGValidateDoc()
|
||||||
|
relaxNGValidateFullElement()
|
||||||
|
relaxNGValidatePopElement()
|
||||||
|
relaxNGValidatePushCData()
|
||||||
|
relaxNGValidatePushElement()
|
||||||
|
@ -235,8 +235,10 @@ xmlFreeRMutex(xmlRMutexPtr tok ATTRIBUTE_UNUSED)
|
|||||||
* xmlRMutexLock() is used to lock a libxml2 token_r.
|
* xmlRMutexLock() is used to lock a libxml2 token_r.
|
||||||
*/
|
*/
|
||||||
void
|
void
|
||||||
xmlRMutexLock(xmlRMutexPtr tok ATTRIBUTE_UNUSED)
|
xmlRMutexLock(xmlRMutexPtr tok)
|
||||||
{
|
{
|
||||||
|
if (tok == NULL)
|
||||||
|
return;
|
||||||
#ifdef HAVE_PTHREAD_H
|
#ifdef HAVE_PTHREAD_H
|
||||||
pthread_mutex_lock(&tok->lock);
|
pthread_mutex_lock(&tok->lock);
|
||||||
if (tok->held) {
|
if (tok->held) {
|
||||||
@ -269,6 +271,8 @@ xmlRMutexLock(xmlRMutexPtr tok ATTRIBUTE_UNUSED)
|
|||||||
void
|
void
|
||||||
xmlRMutexUnlock(xmlRMutexPtr tok ATTRIBUTE_UNUSED)
|
xmlRMutexUnlock(xmlRMutexPtr tok ATTRIBUTE_UNUSED)
|
||||||
{
|
{
|
||||||
|
if (tok == NULL)
|
||||||
|
return;
|
||||||
#ifdef HAVE_PTHREAD_H
|
#ifdef HAVE_PTHREAD_H
|
||||||
pthread_mutex_lock(&tok->lock);
|
pthread_mutex_lock(&tok->lock);
|
||||||
tok->held--;
|
tok->held--;
|
||||||
|
Reference in New Issue
Block a user