[xml] xmlDocDump() fails to dump the DTD



Well, I think this is a bug, but it could just be may total failure to
understand how libXml is supposed to be used :-).

xmlDocDump() fails to dump the DTD. A suggested patch is to add the
following in xmlDocContentDumpOutput() in tree.c.

If the current behaviour is the desired behaviour, I'd appreciate
understanding why.

Thanks,
Bill


[wrking spider libxml2-2.4.12]$ diff -c tree.c tree.c.ORIG
*** tree.c      Sat Jan 19 08:45:43 2002
--- tree.c.ORIG Sat Jan 19 08:39:00 2002
***************
*** 6247,6260 ****
            break;
      }
      xmlOutputBufferWriteString(buf, "?>\n");
-     if (cur->intSubset != NULL) {
-           xmlNodeDumpOutput(buf, cur, (xmlNodePtr) cur->intSubset, 0,
format, encoding);
-           xmlOutputBufferWriteString(buf, "\n");
-     }
-     if (cur->extSubset != NULL) {
-           xmlNodeDumpOutput(buf, cur, (xmlNodePtr) cur->extSubset, 0,
format, encoding);
-           xmlOutputBufferWriteString(buf, "\n");
-     }
      if (cur->children != NULL) {
          xmlNodePtr child = cur->children;

--- 6247,6252 ----




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