"Tinny Ng" <[EMAIL PROTECTED]> writes:

> If it works for most other IDOM methods, except getElementsByTagName(),
> then there may be a bug in this function ....
> 
> Can you post your modified sample program for further investigation?

Here's the version that segfaults using getElementsByTagName().

jas.

Index: IDOMCount.cpp
===================================================================
RCS file: /home/cvspublic/xml-xerces/c/samples/IDOMCount/IDOMCount.cpp,v
retrieving revision 1.3
diff -b -B -u -r1.3 IDOMCount.cpp
--- IDOMCount.cpp       2001/05/28 21:25:01     1.3
+++ IDOMCount.cpp       2001/07/03 21:31:51
@@ -67,6 +67,7 @@
 #include <parsers/IDOMParser.hpp>
 #include <idom/IDOM_DOMException.hpp>
 #include <idom/IDOM_Document.hpp>
+#include <idom/IDOM_DOMImplementation.hpp>
 #include "IDOMCount.hpp"
 #include <string.h>
 #include <stdlib.h>
@@ -269,6 +270,14 @@
      else
     {
         IDOM_Document *doc = parser.getDocument();
+
+       static const XMLCh  foo[] =
+           {
+               chLatin_f, chLatin_o, chLatin_o
+           };
+
+       IDOM_NodeList *list = doc->getElementsByTagName(foo);
+
         unsigned int elementCount = 0;
         if (doc)
             elementCount = countChildElements((IDOM_Node*)doc->getDocumentElement());

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to