[xml] xmlgetNodePath differences on Mac/Win32.



Dear list,
I am statically compiling libxml into a plugin/dll on both Mac (Tiger) and Win32 (XP ProSP2).

I am using binary versions libxml2-2.6.30 (iconv-1.9.2 + zlib-1.2.3) on the Win32 platform and libxml2.2.dylib on the Mac. I am then using a modification of the tree1.c example to print out a recursive list of all the node paths in the XML file.

<fragment>

    for (cur_node = a_node; cur_node ; cur_node = cur_node->next) {
        if (cur_node->type == XML_ELEMENT_NODE) {
                        path = xmlGetNodePath(cur_node);

</fragment>

However, the xmlChar string from xmlGetNodePath() on Win32 and Mac is different! On Mac I get something like:

/xrdMeasurements
/xrdMeasurements/comment
/xrdMeasurements/comment/entry

on Win32 I get

/*
/*/*[1]
/*/*[1]/*

For me the second is useless, is there something I have forgotten to do on win32? Or can anyone suggest code to get the same results I get on the Mac?

regards,
Andy




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