ReactOS
0.4.15-dev-4874-g57c84dd
|
#include "libxml.h"
#include <string.h>
#include <libxml/threads.h>
#include <libxml/globals.h>
#include <sys/types.h>
#include <unistd.h>
#include <stdlib.h>
#include "elfgcchack.h"
Go to the source code of this file.
Classes | |
struct | _xmlMutex |
struct | _xmlRMutex |
Macros | |
#define | IN_LIBXML |
#define | bottom_threads |
Variables | |
static xmlRMutexPtr | xmlLibraryLock = NULL |
#define bottom_threads |
#define IN_LIBXML |
xmlGlobalInitMutexDestroy
Makes sure that the global initialization mutex is destroyed before application termination.
Definition at line 526 of file threads.c.
Referenced by xmlCleanupGlobals().
xmlGlobalInitMutexLock
Makes sure that the global initialization mutex is initialized and locks it.
Definition at line 427 of file threads.c.
Referenced by xmlInitParser().
Definition at line 502 of file threads.c.
Referenced by xmlInitParser().
xmlCleanupThreads:
xmlCleanupThreads() is used to to cleanup all the thread related data of the libxml2 library once processing has ended.
WARNING: if your application is multithreaded or has plugin support calling this may crash the application if another thread or a plugin is still using libxml2. It's sometimes very hard to guess if libxml2 is in use in the application, some libraries or plugins may use it without notice. In case of doubt abstain from calling this function or do it just before calling exit() to avoid leak reports from valgrind !
Definition at line 906 of file threads.c.
Referenced by xmlCleanupParser().
void xmlFreeMutex | ( | xmlMutexPtr | tok | ) |
xmlFreeMutex: @tok: the simple mutex
xmlFreeMutex() is used to reclaim resources associated with a libxml2 token struct.
Definition at line 206 of file threads.c.
Referenced by xmlCleanupGlobals(), xmlCleanupMemory(), xmlFreeRMutex(), and xsltCleanupGlobals().
void xmlFreeRMutex | ( | xmlRMutexPtr tok | ATTRIBUTE_UNUSED | ) |
xmlFreeRMutex: @tok: the reentrant mutex
xmlRFreeMutex() is used to reclaim resources associated with a reentrant mutex.
Definition at line 319 of file threads.c.
Referenced by xmlDictCleanup(), and xsltUninit().
xmlGlobalStatePtr xmlGetGlobalState | ( | void | ) |
xmlGetGlobalState:
xmlGetGlobalState() is called to retrieve the global state for a thread.
Returns the thread global state or NULL in case of error
Definition at line 654 of file threads.c.
Referenced by __oldXMLWDcompatibility(), __xmlBufferAllocScheme(), __xmlDefaultBufferSize(), __xmlDefaultSAXLocator(), __xmlDeregisterNodeDefaultValue(), __xmlDoValidityCheckingDefaultValue(), __xmlGenericError(), __xmlGenericErrorContext(), __xmlGetWarningsDefaultValue(), __xmlIndentTreeOutput(), __xmlKeepBlanksDefaultValue(), __xmlLastError(), __xmlLineNumbersDefaultValue(), __xmlLoadExtDtdDefaultValue(), __xmlOutputBufferCreateFilenameValue(), __xmlParserDebugEntities(), __xmlParserInputBufferCreateFilenameValue(), __xmlParserVersion(), __xmlPedanticParserDefaultValue(), __xmlRegisterNodeDefaultValue(), __xmlSaveNoEmptyTags(), __xmlStructuredError(), __xmlStructuredErrorContext(), __xmlSubstituteEntitiesDefaultValue(), and __xmlTreeIndentString().
xmlGetThreadId:
xmlGetThreadId() find the current thread ID number Note that this is likely to be broken on some platforms using pthreads as the specification doesn't mandate pthread_t to be an integer type
Returns the current thread ID number
Definition at line 764 of file threads.c.
Referenced by xmlInitializeGlobalState().
xmlInitThreads:
xmlInitThreads() is used to to initialize all the thread related data of the libxml2 library.
Definition at line 858 of file threads.c.
Referenced by xmlInitParser(), and xmlIsMainThread().
xmlIsMainThread:
xmlIsMainThread() check whether the current thread is the main thread.
Returns 1 if the current thread is the main thread, 0 otherwise
Definition at line 793 of file threads.c.
xmlLockLibrary:
xmlLockLibrary() is used to take out a re-entrant lock on the libxml2 library.
Definition at line 828 of file threads.c.
void xmlMutexLock | ( | xmlMutexPtr | tok | ) |
xmlMutexLock: @tok: the simple mutex
xmlMutexLock() is used to lock a libxml2 token.
Definition at line 229 of file threads.c.
Referenced by xmlInitializeGlobalState(), xmlMallocAtomicLoc(), xmlMallocLoc(), xmlMemBlocks(), xmlMemDisplay(), xmlMemDisplayLast(), xmlMemFree(), xmlMemShow(), xmlMemStrdupLoc(), xmlMemUsed(), xmlReallocLoc(), xmlRMutexLock(), xmlThrDefBufferAllocScheme(), xmlThrDefDefaultBufferSize(), xmlThrDefDeregisterNodeDefault(), xmlThrDefDoValidityCheckingDefaultValue(), xmlThrDefGetWarningsDefaultValue(), xmlThrDefIndentTreeOutput(), xmlThrDefKeepBlanksDefaultValue(), xmlThrDefLineNumbersDefaultValue(), xmlThrDefLoadExtDtdDefaultValue(), xmlThrDefOutputBufferCreateFilenameDefault(), xmlThrDefParserDebugEntities(), xmlThrDefParserInputBufferCreateFilenameDefault(), xmlThrDefPedanticParserDefaultValue(), xmlThrDefRegisterNodeDefault(), xmlThrDefSaveNoEmptyTags(), xmlThrDefSetGenericErrorFunc(), xmlThrDefSetStructuredErrorFunc(), xmlThrDefSubstituteEntitiesDefaultValue(), xmlThrDefTreeIndentString(), xsltCleanupGlobals(), xsltDebugDumpExtensions(), xsltExtModuleElementLookup(), xsltExtModuleElementPreComputeLookup(), xsltExtModuleFunctionLookup(), xsltExtModuleTopLevelLookup(), xsltGetExtData(), xsltPreComputeExtModuleElement(), xsltRegisterExtModuleElement(), xsltRegisterExtModuleFull(), xsltRegisterExtModuleFunction(), xsltRegisterExtModuleTopLevel(), xsltRegisterExtPrefix(), xsltStyleInitializeStylesheetModule(), xsltUnregisterAllExtModuleElement(), xsltUnregisterAllExtModuleFunction(), xsltUnregisterAllExtModules(), xsltUnregisterAllExtModuleTopLevel(), xsltUnregisterExtModule(), xsltUnregisterExtModuleElement(), xsltUnregisterExtModuleFunction(), and xsltUnregisterExtModuleTopLevel().
void xmlMutexUnlock | ( | xmlMutexPtr | tok | ) |
xmlMutexUnlock: @tok: the simple mutex
xmlMutexUnlock() is used to unlock a libxml2 token.
Definition at line 257 of file threads.c.
Referenced by xmlInitializeGlobalState(), xmlMallocAtomicLoc(), xmlMallocLoc(), xmlMemBlocks(), xmlMemDisplay(), xmlMemDisplayLast(), xmlMemFree(), xmlMemShow(), xmlMemStrdupLoc(), xmlMemUsed(), xmlReallocLoc(), xmlRMutexUnlock(), xmlThrDefBufferAllocScheme(), xmlThrDefDefaultBufferSize(), xmlThrDefDeregisterNodeDefault(), xmlThrDefDoValidityCheckingDefaultValue(), xmlThrDefGetWarningsDefaultValue(), xmlThrDefIndentTreeOutput(), xmlThrDefKeepBlanksDefaultValue(), xmlThrDefLineNumbersDefaultValue(), xmlThrDefLoadExtDtdDefaultValue(), xmlThrDefOutputBufferCreateFilenameDefault(), xmlThrDefParserDebugEntities(), xmlThrDefParserInputBufferCreateFilenameDefault(), xmlThrDefPedanticParserDefaultValue(), xmlThrDefRegisterNodeDefault(), xmlThrDefSaveNoEmptyTags(), xmlThrDefSetGenericErrorFunc(), xmlThrDefSetStructuredErrorFunc(), xmlThrDefSubstituteEntitiesDefaultValue(), xmlThrDefTreeIndentString(), xsltCleanupGlobals(), xsltDebugDumpExtensions(), xsltExtModuleElementLookup(), xsltExtModuleElementPreComputeLookup(), xsltExtModuleFunctionLookup(), xsltExtModuleTopLevelLookup(), xsltGetExtData(), xsltPreComputeExtModuleElement(), xsltRegisterExtModuleElement(), xsltRegisterExtModuleFull(), xsltRegisterExtModuleFunction(), xsltRegisterExtModuleTopLevel(), xsltRegisterExtPrefix(), xsltStyleInitializeStylesheetModule(), xsltUnregisterAllExtModuleElement(), xsltUnregisterAllExtModuleFunction(), xsltUnregisterAllExtModules(), xsltUnregisterAllExtModuleTopLevel(), xsltUnregisterExtModule(), xsltUnregisterExtModuleElement(), xsltUnregisterExtModuleFunction(), and xsltUnregisterExtModuleTopLevel().
xmlMutexPtr xmlNewMutex | ( | void | ) |
xmlNewMutex:
xmlNewMutex() is used to allocate a libxml2 token struct for use in synchronizing access to data.
Returns a new simple mutex pointer or NULL in case of error
Definition at line 177 of file threads.c.
Referenced by xmlInitGlobals(), xmlInitMemory(), xmlNewRMutex(), and xsltInitGlobals().
xmlRMutexPtr xmlNewRMutex | ( | void | ) |
xmlNewRMutex:
xmlRNewMutex() is used to allocate a reentrant mutex for use in synchronizing access to data. token_r is a re-entrant lock and thus useful for synchronizing access to data structures that may be manipulated in a recursive fashion.
Returns the new reentrant mutex pointer or NULL in case of error
Definition at line 285 of file threads.c.
Referenced by __xmlInitializeDict(), and xsltInit().
void xmlRMutexLock | ( | xmlRMutexPtr | tok | ) |
xmlRMutexLock: @tok: the reentrant mutex
xmlRMutexLock() is used to lock a libxml2 token_r.
Definition at line 343 of file threads.c.
Referenced by __xmlInitializeDict(), __xmlRandom(), xmlDictFree(), xmlDictReference(), xmlLockLibrary(), and xsltFreeLocales().
void xmlRMutexUnlock | ( | xmlRMutexPtr tok | ATTRIBUTE_UNUSED | ) |
xmlRMutexUnlock: @tok: the reentrant mutex
xmlRMutexUnlock() is used to unlock a libxml2 token_r.
Definition at line 388 of file threads.c.
Referenced by __xmlInitializeDict(), __xmlRandom(), xmlDictFree(), xmlDictReference(), xmlUnlockLibrary(), and xsltFreeLocales().
xmlUnlockLibrary:
xmlUnlockLibrary() is used to release a re-entrant lock on the libxml2 library.
Definition at line 843 of file threads.c.
|
static |
Definition at line 162 of file threads.c.
Referenced by xmlLockLibrary(), and xmlUnlockLibrary().