Package: libxml++2.6-2
Version: 2.14.0-0.1
Severity: important

Valgrind tool reports about malloc/free disbalance (number of memalloc calls
larger than number of free calls).

example program source:

#include <libxml++/libxml++.h>
#include <iostream>

int main(int argc, char* argv[])
{
        try
        {
                xmlpp::DomParser parser("example.xml");
        }
        catch(...)
        {
                std::cout << "Exception caught" << std::endl;
        }

        return 0;
}

valgrind output:

ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 8 from 1)
malloc/free: in use at exit: 966 bytes in 20 blocks.
malloc/free: 208 allocs, 188 frees, 49,646 bytes allocated.
For counts of detected errors, rerun with: -v
searching for pointers to 20 not-freed blocks.
checked 322,904 bytes.

62 bytes in 8 blocks are still reachable in loss record 1 of 5
   at 0x4A1B858: malloc (vg_replace_malloc.c:149)
   by 0x579982E: xmlStrndup (xmlstring.c:45)
   by 0x572A628: xmlNewCharEncodingHandler (encoding.c:1286)
   by 0x572A734: xmlInitCharEncodingHandlers (encoding.c:1351)
   by 0x5731A99: xmlInitParser (parser.c:12848)
   by 0x4CCBFC2: xmlpp::Document::Init::Init() (in 
/usr/lib/libxml++-2.6.so.2.0.7)
   by 0x4CD5945: (within /usr/lib/libxml++-2.6.so.2.0.7)
   by 0x4CCA0CA: (within /usr/lib/libxml++-2.6.so.2.0.7)


80 bytes in 2 blocks are still reachable in loss record 2 of 5
   at 0x4A1B858: malloc (vg_replace_malloc.c:149)
   by 0x5796ADC: xmlNewMutex (threads.c:180)
   by 0x5796628: xmlInitGlobals (globals.c:49)
   by 0x5731A85: xmlInitParser (parser.c:12845)
   by 0x4CCBFC2: xmlpp::Document::Init::Init() (in 
/usr/lib/libxml++-2.6.so.2.0.7)
   by 0x4CD5945: (within /usr/lib/libxml++-2.6.so.2.0.7)
   by 0x4CCA0CA: (within /usr/lib/libxml++-2.6.so.2.0.7)


104 bytes in 1 blocks are still reachable in loss record 3 of 5
   at 0x4A1B858: malloc (vg_replace_malloc.c:149)
   by 0x5796A8C: xmlNewRMutex (threads.c:287)
   by 0x57E4914: xmlInitializeDict (dict.c:95)
   by 0x57E4B31: xmlDictCreate (dict.c:327)
   by 0x572E2BB: xmlInitParserCtxt (parserInternals.c:1517)
   by 0x572E32D: xmlNewParserCtxt (parserInternals.c:1768)
   by 0x573046C: xmlCreateURLParserCtxt (parser.c:12220)
   by 0x4CCF440: xmlpp::DomParser::parse_file(Glib::ustring const&) (in 
/usr/lib/libxml++-2.6.so.2.0.7)
   by 0x4CCF67C: xmlpp::DomParser::DomParser(Glib::ustring const&, bool) (in 
/usr/lib/libxml++-2.6.so.2.0.7)
   by 0x400D43: main (in /home/skur/devel/sandbox/libxml_test/main)


320 bytes in 8 blocks are still reachable in loss record 4 of 5
   at 0x4A1B858: malloc (vg_replace_malloc.c:149)
   by 0x572A63E: xmlNewCharEncodingHandler (encoding.c:1295)
   by 0x572A734: xmlInitCharEncodingHandlers (encoding.c:1351)
   by 0x5731A99: xmlInitParser (parser.c:12848)
   by 0x4CCBFC2: xmlpp::Document::Init::Init() (in 
/usr/lib/libxml++-2.6.so.2.0.7)
   by 0x4CD5945: (within /usr/lib/libxml++-2.6.so.2.0.7)
   by 0x4CCA0CA: (within /usr/lib/libxml++-2.6.so.2.0.7)


400 bytes in 1 blocks are still reachable in loss record 5 of 5
   at 0x4A1B858: malloc (vg_replace_malloc.c:149)
   by 0x572A6EA: xmlInitCharEncodingHandlers (encoding.c:1337)
   by 0x5731A99: xmlInitParser (parser.c:12848)
   by 0x4CCBFC2: xmlpp::Document::Init::Init() (in 
/usr/lib/libxml++-2.6.so.2.0.7)
   by 0x4CD5945: (within /usr/lib/libxml++-2.6.so.2.0.7)
   by 0x4CCA0CA: (within /usr/lib/libxml++-2.6.so.2.0.7)

LEAK SUMMARY:
   definitely lost: 0 bytes in 0 blocks.
     possibly lost: 0 bytes in 0 blocks.
   still reachable: 966 bytes in 20 blocks.
        suppressed: 0 bytes in 0 blocks.

This situation occurs in both cases, whether example.xml exists of not.


-- System Information:
Debian Release: 4.0
Architecture: i386 (i686)
Shell:  /bin/sh linked to /bin/bash
Kernel: Linux 2.6.18-4-686
Locale: LANG=ru_RU.UTF-8, LC_CTYPE=ru_RU.UTF-8 (charmap=UTF-8)

Versions of packages libxml++2.6-2 depends on:
ii  libc6                  2.3.6.ds1-13etch4 GNU C Library: Shared libraries
ii  libgcc1                1:4.1.1-21        GCC support library
ii  libglib2.0-0           2.12.4-2          The GLib library of C routines
ii  libglibmm-2.4-1c2a     2.12.0-1          C++ wrapper for the GLib toolkit (
ii  libsigc++-2.0-0c2a     2.0.17-2          type-safe Signal Framework for C++
ii  libstdc++6             4.1.1-21          The GNU Standard C++ Library v3
ii  libxml2                2.6.27.dfsg-1     GNOME XML library

libxml++2.6-2 recommends no packages.

-- no debconf information



-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to