[xml] *mlDocDumpMemory[Enc] functions croak?

I've come across a problem using xmlDocDumpMemoryEnc
(and also htmlDocDumpMemory) when using a tree (parsed
HTML) with a certain encoding. Basically this is what
I do (I do have a working reproducable example code,
but haven't attached it here since I don't know if
that's allowed or appropriate):

if(document) { printf("So far so good!\n"); }
xmlChar *xmlbuff; int buffersize;               
// or try:

The code for the file page.html is taken from the site

What happens is that the file is parsed properly, but
when trying to dump it an error occurs:

   output conversion failed due to conv error
   Bytes: 0xCE 0xCE 0xCE 0xCE
   I/O error : encoder error

I find this error odd, since I've specified the same
output encoding as what the tree is.

Now I am blaming these functions by name, but I simply
don't know where the error really is, but it occurs
when I use these functions; this could be an iconv
error, but I find it odd that it would need to convert
to the exact same encoding, let alone have difficulty
doing it... or it could be when the file gets parsed
that something isn't converted right? but when I
process it through stylesheet(s) I haven't seen any
problems... so far.

Or this could simply be my misunderstanding of how to
use these functions? But from what I've been able to
determine, this should be correct.

xsltproc -v reports: Using libxml 20616, libxslt 10109
and libexslt 807


Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]