I have now converted my application to link against the .lib file for my dll
(instead of using LoadLibrary) and now my reports of memory leaks are gone.

I still get the memory leaks if I use LoadLibrary, but I don't think this
will be a problem for me. I'm including the VC++ debug output from a run
where I was using LoadLibrary so that maybe someone will be able to explain
this and/or look at fixing it. I'm not sure if it is really a problem or
not, but here ya go. I'm not even calling into the dll, just loading it:

------------------------------------------------------------------
.
.
<snipped some stuff>
.
.
Loaded symbols for 'C:\WINNT\system32\MSVCIRTD.DLL'
Detected memory leaks!
Dumping objects ->
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {392}
normal block at 0x007DA6C8, 1028 bytes long.
 Data: <                > 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {391}
normal block at 0x007E55C0, 8 bytes long.
 Data: <  }     > C8 A6 7D 00 01 01 00 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {390}
normal block at 0x007E5600, 8 bytes long.
 Data: <     V~ > 94 86 09 12 D0 56 7E 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {389}
normal block at 0x007E5640, 86 bytes long.
 Data: <%       h t t p > 25 00 00 00 01 00 00 00 68 00 74 00 74 00 70 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {388}
normal block at 0x007E56D0, 4 bytes long.
 Data: <0 } > 30 A6 7D 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {387}
normal block at 0x007E5700, 8 bytes long.
 Data: <     W~ > 94 86 09 12 80 57 7E 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {386}
normal block at 0x007E5740, 20 bytes long.
 Data: <        x m l   > 04 00 00 00 01 00 00 00 78 00 6D 00 6C 00 00 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {385}
normal block at 0x007E5780, 4 bytes long.
 Data: <` } > 60 A6 7D 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {384}
normal block at 0x007E57B0, 8 bytes long.
 Data: <    pX~ > 94 86 09 12 70 58 7E 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {383}
normal block at 0x007E57F0, 72 bytes long.
 Data: <        h t t p > 1E 00 00 00 01 00 00 00 68 00 74 00 74 00 70 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {382}
normal block at 0x007E5870, 4 bytes long.
 Data: <H } > 48 A6 7D 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {381}
normal block at 0x007E58A0, 8 bytes long.
 Data: <    0Y~ > 94 86 09 12 30 59 7E 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {380}
normal block at 0x007E58E0, 24 bytes long.
 Data: <        x m l n > 06 00 00 00 01 00 00 00 78 00 6D 00 6C 00 6E 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {379}
normal block at 0x007E5930, 4 bytes long.
 Data: <T } > 54 A6 7D 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {378}
normal block at 0x007E5960, 60 bytes long.
 Data: <         Y~     > D8 88 09 12 00 00 00 00 D0 59 7E 00 18 00 CD CD 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {377}
normal block at 0x007E59D0, 84 bytes long.
 Data: <(w       Y~     > 28 77 09 12 01 00 00 00 D0 59 7E 00 00 00 CD CD 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {376}
normal block at 0x007E5A50, 24 bytes long.
 Data: <        I n p u > 06 00 00 00 01 00 00 00 49 00 6E 00 70 00 75 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {375}
normal block at 0x007D7680, 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) : {374}
normal block at 0x007E5AA0, 24 bytes long.
 Data: < } w            > 10 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) : {373}
normal block at 0x007E5AF0, 4 bytes long.
 Data: < Z~ > A0 5A 7E 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {372}
normal block at 0x007E5B20, 4 bytes long.
 Data: <@   > 40 11 08 12 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {371}
normal block at 0x007E5B50, 4 bytes long.
 Data: <    > A4 11 08 12 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {370}
normal block at 0x007E5B80, 4 bytes long.
 Data: <@   > 40 11 08 12 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {369}
normal block at 0x007E5BB0, 12 bytes long.
 Data: <@\~  @~ p+  > 40 5C 7E 00 80 40 7E 00 70 2B 08 12 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {368}
normal block at 0x007E5BF0, 26 bytes long.
 Data: <W I N D O W S - > 57 00 49 00 4E 00 44 00 4F 00 57 00 53 00 2D 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {367}
normal block at 0x007E5C40, 8 bytes long.
 Data: <     [~ > 04 13 08 12 F0 5B 7E 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {366}
normal block at 0x007E5C80, 12 bytes long.
 Data: < ]~      '  > 00 5D 7E 00 00 00 00 00 88 27 08 12 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {365}
normal block at 0x007E5CC0, 16 bytes long.
 Data: <I B M 1 1 4 0   > 49 00 42 00 4D 00 31 00 31 00 34 00 30 00 00 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {364}
normal block at 0x007E5D00, 8 bytes long.
 Data: <     \~ > 00 13 08 12 C0 5C 7E 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {363}
normal block at 0x007E5D40, 12 bytes long.
 Data: < ]~     x'  > C0 5D 7E 00 00 00 00 00 78 27 08 12 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {362}
normal block at 0x007E5D80, 14 bytes long.
 Data: <I B M 0 3 7   > 49 00 42 00 4D 00 30 00 33 00 37 00 00 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {361}
normal block at 0x007E5DC0, 8 bytes long.
 Data: <     ]~ > FC 12 08 12 80 5D 7E 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {360}
normal block at 0x007E5E00, 12 bytes long.
 Data: < ^~     \'  > 90 5E 7E 00 00 00 00 00 5C 27 08 12 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {359}
normal block at 0x007E5E40, 26 bytes long.
 Data: <E B C D I C - C > 45 00 42 00 43 00 44 00 49 00 43 00 2D 00 43 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {358}
normal block at 0x007E5E90, 8 bytes long.
 Data: <    @^~ > FC 12 08 12 40 5E 7E 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {357}
normal block at 0x007E5ED0, 12 bytes long.
 Data: <P_~      )  > 50 5F 7E 00 00 00 00 00 DC 29 08 12 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {356}
normal block at 0x007E5F10, 16 bytes long.
 Data: <U C S - 4 B E   > 55 00 43 00 53 00 2D 00 34 00 42 00 45 00 00 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {355}
normal block at 0x007E5F50, 12 bytes long.
 Data: <     _~     > F8 12 08 12 10 5F 7E 00 01 CD CD CD 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {354}
normal block at 0x007E5F90, 12 bytes long.
 Data: <@@~      )  > 40 40 7E 00 00 00 00 00 C4 29 08 12 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {353}
normal block at 0x007E5FD0, 22 bytes long.
 Data: <U C S - 4   ( B > 55 00 43 00 53 00 2D 00 34 00 20 00 28 00 42 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {352}
normal block at 0x007E4040, 12 bytes long.
 Data: <     _~     > F8 12 08 12 D0 5F 7E 00 01 CD CD CD 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {351}
normal block at 0x007E4080, 12 bytes long.
 Data: < A~      *  > 00 41 7E 00 00 00 00 00 C8 2A 08 12 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {350}
normal block at 0x007E40C0, 18 bytes long.
 Data: <U T F - 1 6 B E > 55 00 54 00 46 00 2D 00 31 00 36 00 42 00 45 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {349}
normal block at 0x007E4100, 12 bytes long.
 Data: <     @~     > F4 12 08 12 C0 40 7E 00 01 CD CD CD 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {348}
normal block at 0x007E4140, 12 bytes long.
 Data: < A~      *  > D0 41 7E 00 00 00 00 00 B0 2A 08 12 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {347}
normal block at 0x007E4180, 24 bytes long.
 Data: <U T F - 1 6   ( > 55 00 54 00 46 00 2D 00 31 00 36 00 20 00 28 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {346}
normal block at 0x007E41D0, 12 bytes long.
 Data: <     A~     > F4 12 08 12 80 41 7E 00 01 CD CD CD 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {345}
normal block at 0x007E4210, 12 bytes long.
 Data: < B~      *  > 90 42 7E 00 00 00 00 00 04 2A 08 12 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {344}
normal block at 0x007E4250, 16 bytes long.
 Data: <U C S - 4 L E   > 55 00 43 00 53 00 2D 00 34 00 4C 00 45 00 00 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {343}
normal block at 0x007E4290, 12 bytes long.
 Data: <    PB~     > F8 12 08 12 50 42 7E 00 00 CD CD CD 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {342}
normal block at 0x007E42D0, 12 bytes long.
 Data: <`C~      )  > 60 43 7E 00 00 00 00 00 EC 29 08 12 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {341}
normal block at 0x007E4310, 22 bytes long.
 Data: <U C S - 4   ( L > 55 00 43 00 53 00 2D 00 34 00 20 00 28 00 4C 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {340}
normal block at 0x007E4360, 12 bytes long.
 Data: <     C~     > F8 12 08 12 10 43 7E 00 00 CD CD CD 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {339}
normal block at 0x007E43A0, 12 bytes long.
 Data: < D~      *  > 20 44 7E 00 00 00 00 00 F4 2A 08 12 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {338}
normal block at 0x007E43E0, 18 bytes long.
 Data: <U T F - 1 6 L E > 55 00 54 00 46 00 2D 00 31 00 36 00 4C 00 45 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {337}
normal block at 0x007E4420, 12 bytes long.
 Data: <     C~     > F4 12 08 12 E0 43 7E 00 00 CD CD CD 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {336}
normal block at 0x007E4460, 12 bytes long.
 Data: < D~      *  > F0 44 7E 00 00 00 00 00 DC 2A 08 12 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {335}
normal block at 0x007E44A0, 24 bytes long.
 Data: <U T F - 1 6   ( > 55 00 54 00 46 00 2D 00 31 00 36 00 20 00 28 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {334}
normal block at 0x007E44F0, 12 bytes long.
 Data: <     D~     > F4 12 08 12 A0 44 7E 00 00 CD CD CD 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {333}
normal block at 0x007E4530, 12 bytes long.
 Data: < E~     |(  > B0 45 7E 00 00 00 00 00 7C 28 08 12 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {332}
normal block at 0x007E4570, 16 bytes long.
 Data: <L A T I N _ 1   > 4C 00 41 00 54 00 49 00 4E 00 5F 00 31 00 00 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {331}
normal block at 0x007E45B0, 8 bytes long.
 Data: <    pE~ > F0 12 08 12 70 45 7E 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {330}
normal block at 0x007E45F0, 12 bytes long.
 Data: <pF~     l(  > 70 46 7E 00 00 00 00 00 6C 28 08 12 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {329}
normal block at 0x007E4630, 16 bytes long.
 Data: <L A T I N - 1   > 4C 00 41 00 54 00 49 00 4E 00 2D 00 31 00 00 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {328}
normal block at 0x007E4670, 8 bytes long.
 Data: <    0F~ > F0 12 08 12 30 46 7E 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {327}
normal block at 0x007E46B0, 12 bytes long.
 Data: <0G~     \(  > 30 47 7E 00 00 00 00 00 5C 28 08 12 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {326}
normal block at 0x007E46F0, 14 bytes long.
 Data: <L A T I N 1   > 4C 00 41 00 54 00 49 00 4E 00 31 00 00 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {325}
normal block at 0x007E4730, 8 bytes long.
 Data: <     F~ > F0 12 08 12 F0 46 7E 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {324}
normal block at 0x007E4770, 12 bytes long.
 Data: < G~  O~ L(  > F0 47 7E 00 10 4F 7E 00 4C 28 08 12 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {323}
normal block at 0x007E47B0, 14 bytes long.
 Data: <I B M 8 1 9   > 49 00 42 00 4D 00 38 00 31 00 39 00 00 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {322}
normal block at 0x007E47F0, 8 bytes long.
 Data: <     G~ > F0 12 08 12 B0 47 7E 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {321}
normal block at 0x007E4830, 12 bytes long.
 Data: < H~     <(  > B0 48 7E 00 00 00 00 00 3C 28 08 12 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {320}
normal block at 0x007E4870, 16 bytes long.
 Data: <I B M - 8 1 9   > 49 00 42 00 4D 00 2D 00 38 00 31 00 39 00 00 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {319}
normal block at 0x007E48B0, 8 bytes long.
 Data: <    pH~ > F0 12 08 12 70 48 7E 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {318}
normal block at 0x007E48F0, 12 bytes long.
 Data: < I~  M~ $(  > 80 49 7E 00 90 4D 7E 00 24 28 08 12 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {317}
normal block at 0x007E4930, 22 bytes long.
 Data: <I S O _ 8 8 5 9 > 49 00 53 00 4F 00 5F 00 38 00 38 00 35 00 39 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {316}
normal block at 0x007E4980, 8 bytes long.
 Data: <    0I~ > F0 12 08 12 30 49 7E 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {315}
normal block at 0x007E49C0, 12 bytes long.
 Data: <PJ~      (  > 50 4A 7E 00 00 00 00 00 0C 28 08 12 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {314}
normal block at 0x007E4A00, 22 bytes long.
 Data: <I S O - 8 8 5 9 > 49 00 53 00 4F 00 2D 00 38 00 38 00 35 00 39 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {313}
normal block at 0x007E4A50, 8 bytes long.
 Data: <     J~ > F0 12 08 12 00 4A 7E 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {312}
normal block at 0x007E4A90, 12 bytes long.
 Data: < K~      '  > 10 4B 7E 00 00 00 00 00 F8 27 08 12 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {311}
normal block at 0x007E4AD0, 20 bytes long.
 Data: <I S O 8 8 5 9 - > 49 00 53 00 4F 00 38 00 38 00 35 00 39 00 2D 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {310}
normal block at 0x007E4B10, 8 bytes long.
 Data: <     J~ > F0 12 08 12 D0 4A 7E 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {309}
normal block at 0x007E4B50, 12 bytes long.
 Data: < K~     d*  > D0 4B 7E 00 00 00 00 00 64 2A 08 12 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {308}
normal block at 0x007E4B90, 10 bytes long.
 Data: <U T F 8   > 55 00 54 00 46 00 38 00 00 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {307}
normal block at 0x007E4BD0, 8 bytes long.
 Data: <     K~ > EC 12 08 12 90 4B 7E 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {306}
normal block at 0x007E4C10, 12 bytes long.
 Data: < L~     X*  > 90 4C 7E 00 00 00 00 00 58 2A 08 12 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {305}
normal block at 0x007E4C50, 12 bytes long.
 Data: <U T F - 8   > 55 00 54 00 46 00 2D 00 38 00 00 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {304}
normal block at 0x007E4C90, 8 bytes long.
 Data: <    PL~ > EC 12 08 12 50 4C 7E 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {303}
normal block at 0x007E4CD0, 12 bytes long.
 Data: <PM~     D*  > 50 4D 7E 00 00 00 00 00 44 2A 08 12 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {302}
normal block at 0x007E4D10, 18 bytes long.
 Data: <U S _ A S C I I > 55 00 53 00 5F 00 41 00 53 00 43 00 49 00 49 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {301}
normal block at 0x007E4D50, 8 bytes long.
 Data: <     M~ > E8 12 08 12 10 4D 7E 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {300}
normal block at 0x007E4D90, 12 bytes long.
 Data: < N~     8*  > 10 4E 7E 00 00 00 00 00 38 2A 08 12 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {299}
normal block at 0x007E4DD0, 12 bytes long.
 Data: <A S C I I   > 41 00 53 00 43 00 49 00 49 00 00 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {298}
normal block at 0x007E4E10, 8 bytes long.
 Data: <     M~ > E8 12 08 12 D0 4D 7E 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {297}
normal block at 0x007E4E50, 12 bytes long.
 Data: < N~     (*  > D0 4E 7E 00 00 00 00 00 28 2A 08 12 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {296}
normal block at 0x007E4E90, 16 bytes long.
 Data: <U S A S C I I   > 55 00 53 00 41 00 53 00 43 00 49 00 49 00 00 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : {295}
normal block at 0x007E4ED0, 8 bytes long.
 Data: <     N~ > E8 12 08 12 90 4E 7E 00 
D:\Program Files\Microsoft Visual Studio\VC98\INCLUDE\crtdbg.h(552) : The
thread 0x108 has exited with code 0 (0x0).
The program 'D:\SourceCode\xml\leaktest\Debug\leaktest.exe' has exited with
code 0 (0x0).
------------------------------------------------------------------



-----Original Message-----
From: Erik Schroeder [mailto:[EMAIL PROTECTED]]
Sent: Friday, June 08, 2001 10:06 AM
To: '[EMAIL PROTECTED]'
Subject: FW: Memory Leaks (code sample included)


Hi,

I sent this to the list, but it appears that either it did not make it, or I
never received it.  That, or I'm terribly impatient. :)


-----Original Message-----
From: Erik Schroeder 
Sent: Friday, June 08, 2001 6:52 AM
To: '[EMAIL PROTECTED]'
Subject: RE: Memory Leaks (code sample included)


>> In this case memory leaks are reported.
Would you care to include the dump from the output window?


-----Original Message-----
From: Wyles Eric - ewyles [mailto:[EMAIL PROTECTED]]
Sent: Thursday, June 07, 2001 4:26 PM
To: [EMAIL PROTECTED]
Subject: RE: Memory Leaks (code sample included)


OK, I have managed to get rid of all reports of memory leaks, but I still
think there is either a problem or I don't completely understand something
(probably the latter).

What I did was, in my .exe, removed all references to xerces functions and
just passed in a hardcoded character buffer of XML to my dll. Now I do not
get the memory leak messages.

So, I would like someone to shed some light on this if possible. The
situation I don't understand is if I have the following 3:

1) my exe linked against and making xerces calls
2) my dll linked against and making xerces calls
3) my exe linked against my dll (or loading at runtime with LoadLibrary)

In this case memory leaks are reported.

How can I avoid this assuming that I have no control over the exe that will
be using my dll. My exe is only a test application; the dll is the actual
product I'm working on and I may or may not have control over what the
applications that use my dll will do.

Thanks,
Eric


-----Original Message-----
From: Erik Schroeder [mailto:[EMAIL PROTECTED]]
Sent: Thursday, June 07, 2001 2:51 PM
To: '[EMAIL PROTECTED]'
Subject: RE: Memory Leaks (code sample included)


Hi, 
This may not provide any more information, but it would be interesting to
note what happens if you move the XMLPlatformUtils::Initialize() and
XMLPlatformUtils::Terminate() calls into "MyXML.DLL".  Then, in the EXE,
call whatever function in "MyXML.DLL" calls XMLPlatformUtils::Initialize()
prior to doing _anything_ related to Xerces - including declaring variables
of types that are part of Xerces (DOM_DOMImplementation)...  IOW, make sure
that XMLPlatformUtils::Initialize() is called prior to any constructors
within Xerces, etc...

HTH,

Erik

-----Original Message-----
From: Wyles Eric - ewyles [mailto:[EMAIL PROTECTED]]
Sent: Thursday, June 07, 2001 2:42 PM
To: '[EMAIL PROTECTED]'
Subject: RE: Memory Leaks (code sample included)


Thanks for the suggestion, but it didn't seem to have any effect. I'm still
getting reports of leaks.

I don't know if this will trigger any ideas, but I moved my FreeLibrary to
before my Terminate() call and that resulted in even more leaks being
reported by VC++.



-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: Thursday, June 07, 2001 2:25 PM
To: [EMAIL PROTECTED]
Subject: RE: Memory Leaks (code sample included)



Have you tried putting the DOM_Document into an inner scope?  I believe the
Xerces shutdown code will not free things if there are reference counts.
In particular, I think DOMStringHandles are not freed.  Try this:

int main (void)
{
     HMODULE hDllHandle = NULL;
     DOM_DOMImplementation          impl;

     hDllHandle = LoadLibrary("myxml.dll"); // this one causes a leak to be
reported
//         hDllHandle = LoadLibrary("mynonxml.dll"); // this one is ok

      XMLPlatformUtils::Initialize();

     {
          DOM_Document doc = impl.createDocument(
                                          0,
                                          "Input",
                                          DOM_DocumentType());
     }

     XMLPlatformUtils::Terminate();

     FreeLibrary(hDllHandle);

     return 0;
}

All Xerces objects should be destroyed before you attempt th call
XMLPlatformUtils::Terminate().

Dave



 

                    Wyles Eric -

                    ewyles               To:
"'[EMAIL PROTECTED]'" <[EMAIL PROTECTED]>    
                    <Eric.Wyles@a        cc:     (bcc: David N
Bertoni/CAM/Lotus)                                 
                    cxiom.com>           Subject:     RE: Memory Leaks (code
sample included)                     
 

                    06/07/2001

                    02:05 PM

                    Please

                    respond to

                    xerces-c-dev

 

 




In that case though, why would I not see this if I run my application
without loading the dll? Or even if I load a different dll that isn't using
the xerces libraries?

I'm not quite sure I understand what is going on here.

Thanks,
Eric


-----Original Message-----
From: Dean Roddey [mailto:[EMAIL PROTECTED]]
Sent: Thursday, June 07, 2001 12:26 PM
To: '[EMAIL PROTECTED]'
Subject: RE: Memory Leaks (code sample included)


Xerces faults in some static data. These can show up as memory leaks to
some
tools, but they are really just static stuff that is faulted in on first
use, but never released until the program ends. If you really want to test
it, load the DLL, do an initital dummy parse, then take a memory snap shot
and check again just before you call terminate. The first parse will cause
all of the lazy faulting in, so if you take a snapshot after that, anything
that shows up in the exit snap shot is a lot more likely to be a legitimate
leak.

--------------
Dean Roddey
Software Geek Extraordinaire
Portal, Inc
[EMAIL PROTECTED]



-----Original Message-----
From: Wyles Eric - ewyles [mailto:[EMAIL PROTECTED]]
Sent: Thursday, June 07, 2001 9:47 AM
To: '[EMAIL PROTECTED]'
Subject: Memory Leaks (code sample included)


Hi,

I'm having a problem with memory leaks under xerces c++ 1.4.0 on Windows NT
using Visual C++ 6.0. I have two different modules using the xerces api.

1) A very small test application that I have written (code below)
2) A dll that is called by this test application, but will eventually be
called by other users (let's call this one 'myxml.dll')

Both of these are linked against the xerces libraries.


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

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






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

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

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

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

Reply via email to