mirror of
https://gitlab.gnome.org/GNOME/libxml2
synced 2025-03-28 21:33:13 +00:00
try to find more places where xmlCanonicPath() must be used to convert
* DOCBparser.c SAX.c catalog.c debugXML.c parser.c: try to find more places where xmlCanonicPath() must be used to convert filenames to URLs, trying to fix #111088 Daniel
This commit is contained in:
parent
5439624bd9
commit
85095e2c07
@ -1,3 +1,9 @@
|
||||
Wed Apr 23 15:49:32 CEST 2003 Daniel Veillard <daniel@veillard.com>
|
||||
|
||||
* DOCBparser.c SAX.c catalog.c debugXML.c parser.c: try to find
|
||||
more places where xmlCanonicPath() must be used to convert
|
||||
filenames to URLs, trying to fix #111088
|
||||
|
||||
Wed Apr 23 09:35:12 CEST 2003 Daniel Veillard <daniel@veillard.com>
|
||||
|
||||
* python/libxml.c python/libxml.py: applied patch from
|
||||
|
@ -5918,7 +5918,7 @@ docbCreatePushParserCtxt(docbSAXHandlerPtr sax, void *user_data,
|
||||
if (filename == NULL)
|
||||
inputStream->filename = NULL;
|
||||
else
|
||||
inputStream->filename = xmlMemStrdup(filename);
|
||||
inputStream->filename = xmlCanonicPath(filename);
|
||||
inputStream->buf = buf;
|
||||
inputStream->base = inputStream->buf->buffer->content;
|
||||
inputStream->cur = inputStream->buf->buffer->content;
|
||||
@ -6030,8 +6030,7 @@ docbCreateFileParserCtxt(const char *filename,
|
||||
}
|
||||
memset(inputStream, 0, sizeof(docbParserInput));
|
||||
|
||||
inputStream->filename = (char *)
|
||||
xmlCanonicPath((const xmlChar *)filename);
|
||||
inputStream->filename = (char *) xmlCanonicPath((const xmlChar *)filename);
|
||||
inputStream->line = 1;
|
||||
inputStream->col = 1;
|
||||
inputStream->buf = buf;
|
||||
|
2
SAX.c
2
SAX.c
@ -253,7 +253,7 @@ externalSubset(void *ctx, const xmlChar *name,
|
||||
}
|
||||
|
||||
if (input->filename == NULL)
|
||||
input->filename = (char *) xmlStrdup(SystemID);
|
||||
input->filename = (char *) xmlCanonicPath(SystemID);
|
||||
input->line = 1;
|
||||
input->col = 1;
|
||||
input->base = ctxt->input->cur;
|
||||
|
@ -788,7 +788,7 @@ xmlParseCatalogFile(const char *filename) {
|
||||
return(NULL);
|
||||
}
|
||||
|
||||
inputStream->filename = xmlMemStrdup(filename);
|
||||
inputStream->filename = xmlCanonicPath(filename);
|
||||
inputStream->buf = buf;
|
||||
inputStream->base = inputStream->buf->buffer->content;
|
||||
inputStream->cur = inputStream->buf->buffer->content;
|
||||
|
@ -1754,7 +1754,7 @@ xmlShellLoad(xmlShellCtxtPtr ctxt, char *filename,
|
||||
#ifdef LIBXML_XPATH_ENABLED
|
||||
ctxt->pctxt = xmlXPathNewContext(doc);
|
||||
#endif /* LIBXML_XPATH_ENABLED */
|
||||
ctxt->filename = (char *) xmlStrdup((xmlChar *) filename);
|
||||
ctxt->filename = (char *) xmlCanonicPath((xmlChar *) filename);
|
||||
} else
|
||||
return (-1);
|
||||
return (0);
|
||||
|
4
parser.c
4
parser.c
@ -9543,7 +9543,7 @@ xmlSAXParseDTD(xmlSAXHandlerPtr sax, const xmlChar *ExternalID,
|
||||
xmlSwitchEncoding(ctxt, enc);
|
||||
|
||||
if (input->filename == NULL)
|
||||
input->filename = (char *) xmlStrdup(SystemID);
|
||||
input->filename = (char *) xmlCanonicPath(SystemID);
|
||||
input->line = 1;
|
||||
input->col = 1;
|
||||
input->base = ctxt->input->cur;
|
||||
@ -10681,7 +10681,7 @@ xmlSetupParserForBuffer(xmlParserCtxtPtr ctxt, const xmlChar* buffer,
|
||||
|
||||
xmlClearParserCtxt(ctxt);
|
||||
if (filename != NULL)
|
||||
input->filename = xmlMemStrdup(filename);
|
||||
input->filename = xmlCanonicPath(filename);
|
||||
input->base = buffer;
|
||||
input->cur = buffer;
|
||||
input->end = &buffer[xmlStrlen(buffer)];
|
||||
|
Loading…
x
Reference in New Issue
Block a user