1
0
mirror of https://gitlab.gnome.org/GNOME/libxml2.git synced 2025-07-29 11:41:22 +03:00

fixed the data callback on transition functionality which was broken when

* xmlregexp.c: fixed the data callback on transition functionality
  which was broken when using the compact form
* result/schemas/*: updated the results, less verbose, all tests
  pass like before
* DOCBparser.c testAutomata.c testC14N.c testSchemas.c testThreads.c
  testXPath.c valid.c xinclude.c xmllint.c xmlregexp.c xmlschemas.c
  xmlschemastypes.c xpath.c python/libxml.c: removed a bunch of
  annoying warnings
* xpath.c: try to provide better error report when possible
Daniel
This commit is contained in:
Daniel Veillard
2002-09-24 14:13:13 +00:00
parent 7233615a61
commit 118aed78f3
60 changed files with 186 additions and 1515 deletions

View File

@ -156,7 +156,7 @@ xmlPythonFileCloseRaw (void * context) {
#endif
file = (PyObject *) context;
if (file == NULL) return(-1);
ret = PyEval_CallMethod(file, "close", "()");
ret = PyEval_CallMethod(file, (char *) "close", (char *) "()");
if (ret != NULL) {
Py_DECREF(ret);
}
@ -186,7 +186,7 @@ xmlPythonFileReadRaw (void * context, char * buffer, int len) {
#endif
file = (PyObject *) context;
if (file == NULL) return(-1);
ret = PyEval_CallMethod(file, "read", "(i)", len);
ret = PyEval_CallMethod(file, (char *) "read", (char *) "(i)", len);
if (ret == NULL) {
printf("xmlPythonFileReadRaw: result is NULL\n");
return(-1);
@ -227,7 +227,7 @@ xmlPythonFileRead (void * context, char * buffer, int len) {
#endif
file = (PyObject *) context;
if (file == NULL) return(-1);
ret = PyEval_CallMethod(file, "io_read", "(i)", len);
ret = PyEval_CallMethod(file, (char *) "io_read", (char *) "(i)", len);
if (ret == NULL) {
printf("xmlPythonFileRead: result is NULL\n");
return(-1);
@ -270,7 +270,7 @@ xmlPythonFileWrite (void * context, const char * buffer, int len) {
if (file == NULL) return(-1);
string = PyString_FromStringAndSize(buffer, len);
if (string == NULL) return(-1);
ret = PyEval_CallMethod(file, "io_write", "(O)", string);
ret = PyEval_CallMethod(file, (char *) "io_write", (char *) "(O)", string);
Py_DECREF(string);
if (ret == NULL) {
printf("xmlPythonFileWrite: result is NULL\n");
@ -303,7 +303,7 @@ xmlPythonFileClose (void * context) {
#endif
file = (PyObject *) context;
if (file == NULL) return(-1);
ret = PyEval_CallMethod(file, "io_close", "()");
ret = PyEval_CallMethod(file, (char *) "io_close", (char *) "()");
if (ret != NULL) {
Py_DECREF(ret);
}
@ -320,7 +320,7 @@ xmlPythonFileClose (void * context) {
*
* Returns the new parser output or NULL
*/
xmlOutputBufferPtr
static xmlOutputBufferPtr
xmlOutputBufferCreatePythonFile(PyObject *file,
xmlCharEncodingHandlerPtr encoder) {
xmlOutputBufferPtr ret;
@ -351,7 +351,7 @@ libxml_xmlCreateOutputBuffer(ATTRIBUTE_UNUSED PyObject *self, PyObject *args) {
&file, &encoding))
return(NULL);
if ((encoding != NULL) && (encoding[0] != 0)) {
handler = xmlFindCharEncodingHandler(encoding);
handler = xmlFindCharEncodingHandler((const char *) encoding);
}
buffer = xmlOutputBufferCreatePythonFile(file, handler);
if (buffer == NULL)
@ -371,7 +371,7 @@ libxml_xmlCreateOutputBuffer(ATTRIBUTE_UNUSED PyObject *self, PyObject *args) {
*
* Returns the new parser output or NULL
*/
xmlParserInputBufferPtr
static xmlParserInputBufferPtr
xmlParserInputBufferCreatePythonFile(PyObject *file,
xmlCharEncoding encoding) {
xmlParserInputBufferPtr ret;
@ -402,7 +402,7 @@ libxml_xmlCreateInputBuffer(ATTRIBUTE_UNUSED PyObject *self, PyObject *args) {
&file, &encoding))
return(NULL);
if ((encoding != NULL) && (encoding[0] != 0)) {
enc = xmlParseCharEncoding(encoding);
enc = xmlParseCharEncoding((const char *) encoding);
}
buffer = xmlParserInputBufferCreatePythonFile(file, enc);
if (buffer == NULL)
@ -434,7 +434,7 @@ pythonExternalEntityLoader(const char *URL, const char *ID,
#endif
ret = PyObject_CallFunction(pythonExternalEntityLoaderObjext,
"(ssO)", URL, ID, ctxtobj);
(char *) "(ssO)", URL, ID, ctxtobj);
#ifdef DEBUG_LOADER
printf("pythonExternalEntityLoader: result ");
PyObject_Print(ret, stdout, 0);
@ -442,7 +442,7 @@ pythonExternalEntityLoader(const char *URL, const char *ID,
#endif
if (ret != NULL) {
if (PyObject_HasAttrString(ret, "read")) {
if (PyObject_HasAttrString(ret, (char *) "read")) {
xmlParserInputBufferPtr buf;
buf = xmlAllocParserInputBuffer(XML_CHAR_ENCODING_NONE);

View File

@ -351,38 +351,38 @@ Class xmlDoc(xmlNode)
# functions from module xpath
xpathNewContext()
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()
Class xmlAttribute(xmlNode)
Class xmlNs(xmlNode)
# functions from module tree
copyNamespace()
copyNamespaceList()
freeNs()
freeNsList()
newNodeEatName()
# 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()
# functions from module catalog
@ -396,6 +396,27 @@ Class catalog()
resolvePublic()
resolveSystem()
resolveURI()
Class xmlElement(xmlNode)
Class xmlAttr(xmlNode)
# functions from module debugXML
debugDumpAttr()
debugDumpAttrList()
# functions from module tree
freeProp()
freePropList()
removeProp()
Class xmlEntity(xmlNode)
# functions from module parserInternals
handleEntity()
Class xpathParserContext()
# accessors
context()
@ -519,6 +540,44 @@ Class parserCtxt()
stringDecodeEntities()
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()
newNodeEatName()
# functions from module xpathInternals
xpathNodeSetFreeNs()
Class inputBuffer(ioReadWrapper)
# functions from module xmlIO
freeParserInputBuffer()
grow()
push()
read()
Class outputBuffer(ioWriteWrapper)
# functions from module xmlIO
@ -526,27 +585,6 @@ Class outputBuffer(ioWriteWrapper)
flush()
write()
writeString()
Class xmlElement(xmlNode)
Class xmlEntity(xmlNode)
# functions from module parserInternals
handleEntity()
Class xmlAttr(xmlNode)
# functions from module debugXML
debugDumpAttr()
debugDumpAttrList()
# functions from module tree
freeProp()
freePropList()
removeProp()
Class URI()
# accessors
authority()
@ -573,41 +611,3 @@ Class URI()
parseURIReference()
printURI()
saveUri()
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()
Class inputBuffer(ioReadWrapper)
# functions from module xmlIO
freeParserInputBuffer()
grow()
push()
read()