mirror of
https://gitlab.gnome.org/GNOME/libxml2.git
synced 2025-07-28 00:21:53 +03:00
the uri arg to xmlNodeSetBase is really a const xmlChar* addin the
* tree.c include/libxml/tree.h: the uri arg to xmlNodeSetBase is really a const xmlChar* * xmlreader.c include/libxml/xmlreader.h: addin the xmlTextReaderConstString() to get an interned string from the reader Daniel
This commit is contained in:
18
xmlreader.c
18
xmlreader.c
@ -2991,6 +2991,24 @@ xmlTextReaderConstXmlLang(xmlTextReaderPtr reader) {
|
||||
return(ret);
|
||||
}
|
||||
|
||||
/**
|
||||
* xmlTextReaderConstString:
|
||||
* @reader: the xmlTextReaderPtr used
|
||||
* @str: the string to intern.
|
||||
*
|
||||
* Get an interned string from the reader, allows for example to
|
||||
* speedup string name comparisons
|
||||
*
|
||||
* Returns an interned copy of the string or NULL in case of error. The
|
||||
* string will be deallocated with the reader.
|
||||
*/
|
||||
const xmlChar *
|
||||
xmlTextReaderConstString(xmlTextReaderPtr reader, const xmlChar *str) {
|
||||
if (reader == NULL)
|
||||
return(NULL);
|
||||
return(CONSTSTR(str));
|
||||
}
|
||||
|
||||
/**
|
||||
* xmlTextReaderNormalization:
|
||||
* @reader: the xmlTextReaderPtr used
|
||||
|
Reference in New Issue
Block a user