You are viewing a plain text version of this content. The canonical link for it is here.
Posted to c-dev@xerces.apache.org by Andy Heninger <an...@jtcsv.com> on 2000/10/23 19:59:25 UTC

Re: DOMParser leak

I ran your file through DOMPrint, and BoundsChecker did
not report any leaks.  I tried with and without validation,
with and without namespaces.

I don't believe that there have been any leak fixes between
1.3.0 and the current code.  But maybe something changed.
Could you try again with the latest nightly build?

If you still see a leak, do your tools give any additional
information about where the leak is coming from?   (Bounds-
checker is really good at this - it shows the offending
block and a full stack trace for where in the code it
was allocated.)

Andy Heninger
IBM XML Technology Group, Cupertino, CA
heninger@us.ibm.com


----- Original Message -----
From: "Joel C. Lim" <jl...@ntsp.nec.co.jp>
To: <xe...@xml.apache.org>
Sent: Monday, October 23, 2000 6:46 PM
Subject: DOMParser leak


> Hi all,
>
> Greetings!!!
>
> I have a slight problem with xerces-c 1.3.0 for Win32.
> I am using Visual C++ 6.0.  I think DOMParser has
> a leak.  The wierd thing is that leak only appears
> to only one of my XML files.  The leak does not appear
> when I used 1.2.0.  duh?
>
> Can someone please help me?
>
> Thanks in advance.
>
> joel
>
>
> My code is as follows:
>
//************************************************************************
**
> ****************************
> DOMParser psrAIDList;
> CErrorHandler oErrorHandler;
>
> psrAIDList.setDoValidation(false);
> psrAIDList.setErrorHandler( &oErrorHandler );
>
> try
> {
> psrAIDList.parse(szFile);
> }
> catch (const XMLException& toCatch)
> {
> CString szError;
> szError.Format( "Error during parsing: %s : %s", szFile,
> MLCh_to_String( toCatch.getMessage() ) );
>
> #ifdef _DEBUG
> AfxMessageBox( "LoadSchemas::"+szError, MB_ICONERROR );
> #endif
>
> return FALSE;
> }
>
//************************************************************************
**
> ****************************
>
> My XML file:
>
//************************************************************************
**
> ****************************
> <!DOCTYPE AID
> [
> <!ELEMENT AID (OBJECT*)>
> <!ATTLIST AID TARGET_NE CDATA #REQUIRED>
> <!ATTLIST AID FORMAT CDATA #REQUIRED>
>
> <!ATTLIST AID SLOT CDATA #REQUIRED>
>
> <!ELEMENT OBJECT (PROPERTY*)>
> <!ATTLIST OBJECT NAME CDATA #REQUIRED>
>
> <!ELEMENT PROPERTY (#PCDATA)>
> <!ATTLIST PROPERTY NAME  CDATA #REQUIRED>
> <!ATTLIST PROPERTY VALUE CDATA #REQUIRED>
> ]>
>
> <AID TARGET_NE="SPWV80 TERM"
FORMAT="OBJECT-[BAY]-[SHELF]-[SLOT]-[CHANNEL]"
> SLOT="SHELF[1-39]-[1-3]-[0-22]">
> </AID>
>
**************************************************************************
**
> **************************//
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: xerces-c-dev-unsubscribe@xml.apache.org
> For additional commands, e-mail: xerces-c-dev-help@xml.apache.org
>
>


Re: DOMParser leak

Posted by Hal DeVore <ha...@acm.org>.
>>>>> On Mon, 23 Oct 2000, "Joe" == Joe Pruitt wrote:

  Joe> With VC++ it's pretty easy to tell which you are
  Joe> importing.

  Joe> dumpbin.exe /imports yourapp.exe

  Joe> And look for which version of xerces you are importing.
  Joe> Also look for the msvcrt*.dll which is in the import list.

  Joe> Then do the same for the xerces dll that was in the import
  Joe> list for your app.

  Joe> dumpbin /imports xerces-???.dll


On my system at least, right clicking on a binary or dll in
Windows Explorer and selecting QuickView gives the the imports
and some of the other info that dumpbin generates.  I guess this
is running dumpbin or doing whatever system call dumpbin uses to
get the info.

There is also a "View Dependencies" item on the popup menu that
is "wired up" to run depends.exe. depends.exe is an even more
informative way to explore the libraries and functions you're
importing because it will follow on down to what those libraries
are importing and on down.  It also shows you a list of all the
files involved with timestamps and other useful info.

depends.exe should be in your visual studio
common/tools directory.

--Hal



RE: DOMParser leak

Posted by "Joel C. Lim" <jl...@ntsp.nec.co.jp>.
Hello everyone,

In the source code located in this URL:
http://xml.apache.org/dist/xerces-c/stable/xerces-c-src1_3_0.zip

using the test program sent yeseterday,

Boundschecker 6.0 reported the following memory leaks:

Memory leak
12292 bytes allocated by operator new in
D:\xerces-c-src1_3_0\src\dom\DOMString.cpp (289), HANDLE: 0x02A1BED0
Memory leak
24 bytes allocated by operator new in
D:\xerces-c-src1_3_0\src\util\Platforms\Win32\Win32PlatformUtils.cpp (605),
HANDLE: 0x02A29130
Memory leak
4 bytes allocated by operator new in
D:\xerces-c-src1_3_0\src\dom\DOMString.cpp (259), HANDLE: 0x02A29180
Memory leak
48 bytes allocated by operator new in
D:\xerces-c-src1_3_0\src\dom\DocumentImpl.cpp (286), HANDLE: 0x02A2A370
Memory leak
48 bytes allocated by operator new in
D:\xerces-c-src1_3_0\src\dom\DocumentImpl.cpp (286), HANDLE: 0x02A2A370

I am still looking for the routine where the instances are deleted.  Is
there a routine/class that handles
all the clean-up.  What is the class name for the xerces's garbage
collector?

Your inputs are highly appreciated.

thanks,
joel


-----Original Message-----
From: Joe Pruitt [mailto:j.pruitt@f5.com]
Sent: Monday, October 23, 2000 10:57 PM
To: xerces-c-dev@xml.apache.org
Subject: RE: DOMParser leak


Are you compiling your app with the same C runtime as the xerces dll?  Line
552 of crtdbg.h is for operator new which points me to
incompatible compiling options.

With VC++ it's pretty easy to tell which you are importing.

	dumpbin.exe /imports yourapp.exe

And look for which version of xerces you are importing.  Also look for the
msvcrt*.dll which is in the import list.

Then do the same for the xerces dll that was in the import list for your
app.

	dumpbin /imports xerces-???.dll

Chances are that the msvcrt?.dll don't match.  If you are linking with the
Debug version of xerces then you will have to modify your
C++ options for your project to use the "Debug Multithreaded DLL".  For the
release version use "Multithreaded DLL".

-Joe

> -----Original Message-----
> From: Joel C. Lim [mailto:jlim@ntsp.nec.co.jp]
> Sent: Tuesday, October 24, 2000 7:22 AM
> To: xerces-c-dev@xml.apache.org
> Subject: RE: DOMParser leak
>
>
> Hello Andy,
>
> The leak reported was by Visual C++.
>
> Detected memory leaks!
> Dumping objects ->
> D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) :
{796}
> normal block at 0x008FBA00, 48 bytes long.
>  Data: < h      P       > 10 68 09 12 00 00 00 00 50 98 8F 00 00 00 CD CD
> D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) :
{795}
> normal block at 0x008FBA60, 30 bytes long.
>  Data: <        P R O P > 09 00 00 00 01 00 00 00 50 00 52 00 4F 00 50 00
> D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) :
{660}
> normal block at 0x008FA3B0, 48 bytes long.
>  Data: < h      P       > 10 68 09 12 00 00 00 00 50 98 8F 00 00 00 CD CD
> D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) :
{631}
> normal block at 0x008FA580, 48 bytes long.
>  Data: < h      P       > 10 68 09 12 00 00 00 00 50 98 8F 00 00 00 CD CD
> D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) :
{630}
> normal block at 0x008FA890, 20 bytes long.
>  Data: <        A I D   > 04 00 00 00 02 00 00 00 41 00 49 00 44 00 00 00
> D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) :
{551}
> normal block at 0x008EB908, 12292 bytes long.
>  Data: <                > 00 04 00 00 00 00 00 00 CD CD CD CD CD CD CD CD
> D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) :
{550}
> normal block at 0x008F91F0, 24 bytes long.
>  Data: <@} w            > 40 7D FA 77 FF FF FF FF 00 00 00 00 00 00 00 00
> D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) :
{549}
> normal block at 0x008F9240, 4 bytes long.
>  Data: <    > F0 91 8F 00
> Object dump complete.
> The thread 0x181 has exited with code 0 (0x0).
>
> Attached is a sample program source.
> Is it ok if I download the xerces-c source code and debugged it from here?
>
> Thanks for all your help.
>
> best regards,
> joel
>
>
> -----Original Message-----
> From: Andy Heninger [mailto:andyh@jtcsv.com]
> Sent: Monday, October 23, 2000 12:59 PM
> To: xerces-c-dev@xml.apache.org
> Subject: Re: DOMParser leak
>
>
> I ran your file through DOMPrint, and BoundsChecker did
> not report any leaks.  I tried with and without validation,
> with and without namespaces.
>
> I don't believe that there have been any leak fixes between
> 1.3.0 and the current code.  But maybe something changed.
> Could you try again with the latest nightly build?
>
> If you still see a leak, do your tools give any additional
> information about where the leak is coming from?   (Bounds-
> checker is really good at this - it shows the offending
> block and a full stack trace for where in the code it
> was allocated.)
>
> Andy Heninger
> IBM XML Technology Group, Cupertino, CA
> heninger@us.ibm.com
>
>
> ----- Original Message -----
> From: "Joel C. Lim" <jl...@ntsp.nec.co.jp>
> To: <xe...@xml.apache.org>
> Sent: Monday, October 23, 2000 6:46 PM
> Subject: DOMParser leak
>
>
> > Hi all,
> >
> > Greetings!!!
> >
> > I have a slight problem with xerces-c 1.3.0 for Win32.
> > I am using Visual C++ 6.0.  I think DOMParser has
> > a leak.  The wierd thing is that leak only appears
> > to only one of my XML files.  The leak does not appear
> > when I used 1.2.0.  duh?
> >
> > Can someone please help me?
> >
> > Thanks in advance.
> >
> > joel
> >
> >
> > My code is as follows:
> >
> //************************************************************************
> **
> > ****************************
> > DOMParser psrAIDList;
> > CErrorHandler oErrorHandler;
> >
> > psrAIDList.setDoValidation(false);
> > psrAIDList.setErrorHandler( &oErrorHandler );
> >
> > try
> > {
> > psrAIDList.parse(szFile);
> > }
> > catch (const XMLException& toCatch)
> > {
> > CString szError;
> > szError.Format( "Error during parsing: %s : %s", szFile,
> > MLCh_to_String( toCatch.getMessage() ) );
> >
> > #ifdef _DEBUG
> > AfxMessageBox( "LoadSchemas::"+szError, MB_ICONERROR );
> > #endif
> >
> > return FALSE;
> > }
> >
> //************************************************************************
> **
> > ****************************
> >
> > My XML file:
> >
> //************************************************************************
> **
> > ****************************
> > <!DOCTYPE AID
> > [
> > <!ELEMENT AID (OBJECT*)>
> > <!ATTLIST AID TARGET_NE CDATA #REQUIRED>
> > <!ATTLIST AID FORMAT CDATA #REQUIRED>
> >
> > <!ATTLIST AID SLOT CDATA #REQUIRED>
> >
> > <!ELEMENT OBJECT (PROPERTY*)>
> > <!ATTLIST OBJECT NAME CDATA #REQUIRED>
> >
> > <!ELEMENT PROPERTY (#PCDATA)>
> > <!ATTLIST PROPERTY NAME  CDATA #REQUIRED>
> > <!ATTLIST PROPERTY VALUE CDATA #REQUIRED>
> > ]>
> >
> > <AID TARGET_NE="SPWV80 TERM"
> FORMAT="OBJECT-[BAY]-[SHELF]-[SLOT]-[CHANNEL]"
> > SLOT="SHELF[1-39]-[1-3]-[0-22]">
> > </AID>
> >
> **************************************************************************
> **
> > **************************//
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: xerces-c-dev-unsubscribe@xml.apache.org
> > For additional commands, e-mail: xerces-c-dev-help@xml.apache.org
> >
> >
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: xerces-c-dev-unsubscribe@xml.apache.org
> For additional commands, e-mail: xerces-c-dev-help@xml.apache.org
>
>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: xerces-c-dev-unsubscribe@xml.apache.org
For additional commands, e-mail: xerces-c-dev-help@xml.apache.org



RE: DOMParser leak

Posted by Joe Pruitt <j....@f5.com>.
Are you compiling your app with the same C runtime as the xerces dll?  Line 552 of crtdbg.h is for operator new which points me to
incompatible compiling options.

With VC++ it's pretty easy to tell which you are importing.

	dumpbin.exe /imports yourapp.exe

And look for which version of xerces you are importing.  Also look for the msvcrt*.dll which is in the import list.

Then do the same for the xerces dll that was in the import list for your app.

	dumpbin /imports xerces-???.dll

Chances are that the msvcrt?.dll don't match.  If you are linking with the Debug version of xerces then you will have to modify your
C++ options for your project to use the "Debug Multithreaded DLL".  For the release version use "Multithreaded DLL".

-Joe

> -----Original Message-----
> From: Joel C. Lim [mailto:jlim@ntsp.nec.co.jp]
> Sent: Tuesday, October 24, 2000 7:22 AM
> To: xerces-c-dev@xml.apache.org
> Subject: RE: DOMParser leak
>
>
> Hello Andy,
>
> The leak reported was by Visual C++.
>
> Detected memory leaks!
> Dumping objects ->
> D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {796}
> normal block at 0x008FBA00, 48 bytes long.
>  Data: < h      P       > 10 68 09 12 00 00 00 00 50 98 8F 00 00 00 CD CD
> D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {795}
> normal block at 0x008FBA60, 30 bytes long.
>  Data: <        P R O P > 09 00 00 00 01 00 00 00 50 00 52 00 4F 00 50 00
> D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {660}
> normal block at 0x008FA3B0, 48 bytes long.
>  Data: < h      P       > 10 68 09 12 00 00 00 00 50 98 8F 00 00 00 CD CD
> D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {631}
> normal block at 0x008FA580, 48 bytes long.
>  Data: < h      P       > 10 68 09 12 00 00 00 00 50 98 8F 00 00 00 CD CD
> D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {630}
> normal block at 0x008FA890, 20 bytes long.
>  Data: <        A I D   > 04 00 00 00 02 00 00 00 41 00 49 00 44 00 00 00
> D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {551}
> normal block at 0x008EB908, 12292 bytes long.
>  Data: <                > 00 04 00 00 00 00 00 00 CD CD CD CD CD CD CD CD
> D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {550}
> normal block at 0x008F91F0, 24 bytes long.
>  Data: <@} w            > 40 7D FA 77 FF FF FF FF 00 00 00 00 00 00 00 00
> D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {549}
> normal block at 0x008F9240, 4 bytes long.
>  Data: <    > F0 91 8F 00
> Object dump complete.
> The thread 0x181 has exited with code 0 (0x0).
>
> Attached is a sample program source.
> Is it ok if I download the xerces-c source code and debugged it from here?
>
> Thanks for all your help.
>
> best regards,
> joel
>
>
> -----Original Message-----
> From: Andy Heninger [mailto:andyh@jtcsv.com]
> Sent: Monday, October 23, 2000 12:59 PM
> To: xerces-c-dev@xml.apache.org
> Subject: Re: DOMParser leak
>
>
> I ran your file through DOMPrint, and BoundsChecker did
> not report any leaks.  I tried with and without validation,
> with and without namespaces.
>
> I don't believe that there have been any leak fixes between
> 1.3.0 and the current code.  But maybe something changed.
> Could you try again with the latest nightly build?
>
> If you still see a leak, do your tools give any additional
> information about where the leak is coming from?   (Bounds-
> checker is really good at this - it shows the offending
> block and a full stack trace for where in the code it
> was allocated.)
>
> Andy Heninger
> IBM XML Technology Group, Cupertino, CA
> heninger@us.ibm.com
>
>
> ----- Original Message -----
> From: "Joel C. Lim" <jl...@ntsp.nec.co.jp>
> To: <xe...@xml.apache.org>
> Sent: Monday, October 23, 2000 6:46 PM
> Subject: DOMParser leak
>
>
> > Hi all,
> >
> > Greetings!!!
> >
> > I have a slight problem with xerces-c 1.3.0 for Win32.
> > I am using Visual C++ 6.0.  I think DOMParser has
> > a leak.  The wierd thing is that leak only appears
> > to only one of my XML files.  The leak does not appear
> > when I used 1.2.0.  duh?
> >
> > Can someone please help me?
> >
> > Thanks in advance.
> >
> > joel
> >
> >
> > My code is as follows:
> >
> //************************************************************************
> **
> > ****************************
> > DOMParser psrAIDList;
> > CErrorHandler oErrorHandler;
> >
> > psrAIDList.setDoValidation(false);
> > psrAIDList.setErrorHandler( &oErrorHandler );
> >
> > try
> > {
> > psrAIDList.parse(szFile);
> > }
> > catch (const XMLException& toCatch)
> > {
> > CString szError;
> > szError.Format( "Error during parsing: %s : %s", szFile,
> > MLCh_to_String( toCatch.getMessage() ) );
> >
> > #ifdef _DEBUG
> > AfxMessageBox( "LoadSchemas::"+szError, MB_ICONERROR );
> > #endif
> >
> > return FALSE;
> > }
> >
> //************************************************************************
> **
> > ****************************
> >
> > My XML file:
> >
> //************************************************************************
> **
> > ****************************
> > <!DOCTYPE AID
> > [
> > <!ELEMENT AID (OBJECT*)>
> > <!ATTLIST AID TARGET_NE CDATA #REQUIRED>
> > <!ATTLIST AID FORMAT CDATA #REQUIRED>
> >
> > <!ATTLIST AID SLOT CDATA #REQUIRED>
> >
> > <!ELEMENT OBJECT (PROPERTY*)>
> > <!ATTLIST OBJECT NAME CDATA #REQUIRED>
> >
> > <!ELEMENT PROPERTY (#PCDATA)>
> > <!ATTLIST PROPERTY NAME  CDATA #REQUIRED>
> > <!ATTLIST PROPERTY VALUE CDATA #REQUIRED>
> > ]>
> >
> > <AID TARGET_NE="SPWV80 TERM"
> FORMAT="OBJECT-[BAY]-[SHELF]-[SLOT]-[CHANNEL]"
> > SLOT="SHELF[1-39]-[1-3]-[0-22]">
> > </AID>
> >
> **************************************************************************
> **
> > **************************//
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: xerces-c-dev-unsubscribe@xml.apache.org
> > For additional commands, e-mail: xerces-c-dev-help@xml.apache.org
> >
> >
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: xerces-c-dev-unsubscribe@xml.apache.org
> For additional commands, e-mail: xerces-c-dev-help@xml.apache.org
>
>
>


RE: DOMParser leak

Posted by "Joel C. Lim" <jl...@ntsp.nec.co.jp>.
Hello Andy,

The leak reported was by Visual C++.

Detected memory leaks!
Dumping objects ->
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {796}
normal block at 0x008FBA00, 48 bytes long.
 Data: < h      P       > 10 68 09 12 00 00 00 00 50 98 8F 00 00 00 CD CD
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {795}
normal block at 0x008FBA60, 30 bytes long.
 Data: <        P R O P > 09 00 00 00 01 00 00 00 50 00 52 00 4F 00 50 00
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {660}
normal block at 0x008FA3B0, 48 bytes long.
 Data: < h      P       > 10 68 09 12 00 00 00 00 50 98 8F 00 00 00 CD CD
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {631}
normal block at 0x008FA580, 48 bytes long.
 Data: < h      P       > 10 68 09 12 00 00 00 00 50 98 8F 00 00 00 CD CD
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {630}
normal block at 0x008FA890, 20 bytes long.
 Data: <        A I D   > 04 00 00 00 02 00 00 00 41 00 49 00 44 00 00 00
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {551}
normal block at 0x008EB908, 12292 bytes long.
 Data: <                > 00 04 00 00 00 00 00 00 CD CD CD CD CD CD CD CD
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {550}
normal block at 0x008F91F0, 24 bytes long.
 Data: <@} w            > 40 7D FA 77 FF FF FF FF 00 00 00 00 00 00 00 00
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {549}
normal block at 0x008F9240, 4 bytes long.
 Data: <    > F0 91 8F 00
Object dump complete.
The thread 0x181 has exited with code 0 (0x0).

Attached is a sample program source.
Is it ok if I download the xerces-c source code and debugged it from here?

Thanks for all your help.

best regards,
joel


-----Original Message-----
From: Andy Heninger [mailto:andyh@jtcsv.com]
Sent: Monday, October 23, 2000 12:59 PM
To: xerces-c-dev@xml.apache.org
Subject: Re: DOMParser leak


I ran your file through DOMPrint, and BoundsChecker did
not report any leaks.  I tried with and without validation,
with and without namespaces.

I don't believe that there have been any leak fixes between
1.3.0 and the current code.  But maybe something changed.
Could you try again with the latest nightly build?

If you still see a leak, do your tools give any additional
information about where the leak is coming from?   (Bounds-
checker is really good at this - it shows the offending
block and a full stack trace for where in the code it
was allocated.)

Andy Heninger
IBM XML Technology Group, Cupertino, CA
heninger@us.ibm.com


----- Original Message -----
From: "Joel C. Lim" <jl...@ntsp.nec.co.jp>
To: <xe...@xml.apache.org>
Sent: Monday, October 23, 2000 6:46 PM
Subject: DOMParser leak


> Hi all,
>
> Greetings!!!
>
> I have a slight problem with xerces-c 1.3.0 for Win32.
> I am using Visual C++ 6.0.  I think DOMParser has
> a leak.  The wierd thing is that leak only appears
> to only one of my XML files.  The leak does not appear
> when I used 1.2.0.  duh?
>
> Can someone please help me?
>
> Thanks in advance.
>
> joel
>
>
> My code is as follows:
>
//************************************************************************
**
> ****************************
> DOMParser psrAIDList;
> CErrorHandler oErrorHandler;
>
> psrAIDList.setDoValidation(false);
> psrAIDList.setErrorHandler( &oErrorHandler );
>
> try
> {
> psrAIDList.parse(szFile);
> }
> catch (const XMLException& toCatch)
> {
> CString szError;
> szError.Format( "Error during parsing: %s : %s", szFile,
> MLCh_to_String( toCatch.getMessage() ) );
>
> #ifdef _DEBUG
> AfxMessageBox( "LoadSchemas::"+szError, MB_ICONERROR );
> #endif
>
> return FALSE;
> }
>
//************************************************************************
**
> ****************************
>
> My XML file:
>
//************************************************************************
**
> ****************************
> <!DOCTYPE AID
> [
> <!ELEMENT AID (OBJECT*)>
> <!ATTLIST AID TARGET_NE CDATA #REQUIRED>
> <!ATTLIST AID FORMAT CDATA #REQUIRED>
>
> <!ATTLIST AID SLOT CDATA #REQUIRED>
>
> <!ELEMENT OBJECT (PROPERTY*)>
> <!ATTLIST OBJECT NAME CDATA #REQUIRED>
>
> <!ELEMENT PROPERTY (#PCDATA)>
> <!ATTLIST PROPERTY NAME  CDATA #REQUIRED>
> <!ATTLIST PROPERTY VALUE CDATA #REQUIRED>
> ]>
>
> <AID TARGET_NE="SPWV80 TERM"
FORMAT="OBJECT-[BAY]-[SHELF]-[SLOT]-[CHANNEL]"
> SLOT="SHELF[1-39]-[1-3]-[0-22]">
> </AID>
>
**************************************************************************
**
> **************************//
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: xerces-c-dev-unsubscribe@xml.apache.org
> For additional commands, e-mail: xerces-c-dev-help@xml.apache.org
>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: xerces-c-dev-unsubscribe@xml.apache.org
For additional commands, e-mail: xerces-c-dev-help@xml.apache.org