diff options
| author | Ilia Alshanetsky <iliaa@php.net> | 2008-05-23 15:46:54 +0000 |
|---|---|---|
| committer | Ilia Alshanetsky <iliaa@php.net> | 2008-05-23 15:46:54 +0000 |
| commit | c29dac2f3211bb0ff9c4ab496b55febc548f4979 (patch) | |
| tree | d867cc3b8b1f54894339a7bfb891ce025fce7fc2 /ext | |
| parent | fa6c5d542945fef15d144f6cde05b78cdf02cf52 (diff) | |
| download | php-git-c29dac2f3211bb0ff9c4ab496b55febc548f4979.tar.gz | |
When dumping entire document to file via asXml() don't lose the encoding
Diffstat (limited to 'ext')
| -rw-r--r-- | ext/simplexml/simplexml.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/ext/simplexml/simplexml.c b/ext/simplexml/simplexml.c index c0659e9f07..03320bf2ff 100644 --- a/ext/simplexml/simplexml.c +++ b/ext/simplexml/simplexml.c @@ -1323,7 +1323,7 @@ SXE_METHOD(asXML) if (node) { if (node->parent && (XML_DOCUMENT_NODE == node->parent->type)) { - xmlDocDumpMemory((xmlDocPtr) sxe->document->ptr, &strval, &strval_len); + xmlDocDumpMemoryEnc((xmlDocPtr) sxe->document->ptr, &strval, &strval_len, ((xmlDocPtr) sxe->document->ptr)->encoding); RETVAL_STRINGL((char *)strval, strval_len, 1); xmlFree(strval); } else { |
