$ valgrind ./a.out ==31875== Memcheck, a memory error detector ==31875== Copyright (C) 2002-2011, and GNU GPL'd, by Julian Seward et al. ==31875== Using Valgrind-3.7.0 and LibVEX; rerun with -h for copyright info ==31875== Command: ./a.out ==31875== ==31875== Invalid write of size 8 ==31875== at 0x4F7FEC6: Gst::PlayBin2_Class::class_init_function(void*, void*) (in /usr/lib/libgstreamermm-0.10.so.2.0.1) ==31875== by 0x6A33626: g_type_class_ref (in /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.3200.3) ==31875== by 0x5839286: Glib::ConstructParams::ConstructParams(Glib::Class const&, char const*, ...) (in /usr/lib/x86_64-linux-gnu/libglibmm-2.4.so.1.3.0) ==31875== by 0x4F80D79: Gst::PlayBin2::PlayBin2() (in /usr/lib/libgstreamermm-0.10.so.2.0.1) ==31875== by 0x4F81395: Gst::PlayBin2::create() (in /usr/lib/libgstreamermm-0.10.so.2.0.1) ==31875== by 0x40067C: main (main.cpp:6) ==31875== Address 0xaab0b38 is 0 bytes after a block of size 712 alloc'd ==31875== at 0x4C29DB4: calloc (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so) ==31875== by 0x6FFCAE0: g_malloc0 (in /lib/x86_64-linux-gnu/libglib-2.0.so.0.3200.3) ==31875== by 0x6A33575: g_type_class_ref (in /usr/lib/x86_64-linux-gnu/libgobject-2.0.so.0.3200.3) ==31875== by 0x5839286: Glib::ConstructParams::ConstructParams(Glib::Class const&, char const*, ...) (in /usr/lib/x86_64-linux-gnu/libglibmm-2.4.so.1.3.0) ==31875== by 0x4F80D79: Gst::PlayBin2::PlayBin2() (in /usr/lib/libgstreamermm-0.10.so.2.0.1) ==31875== by 0x4F81395: Gst::PlayBin2::create() (in /usr/lib/libgstreamermm-0.10.so.2.0.1) ==31875== by 0x40067C: main (main.cpp:6) ==31875== ==31875== ==31875== HEAP SUMMARY: ==31875== in use at exit: 4,570,794 bytes in 13,626 blocks ==31875== total heap usage: 45,026 allocs, 31,400 frees, 49,283,724 bytes allocated ==31875== ==31875== LEAK SUMMARY: ==31875== definitely lost: 16,444 bytes in 2 blocks ==31875== indirectly lost: 240 bytes in 10 blocks ==31875== possibly lost: 481,657 bytes in 2,302 blocks ==31875== still reachable: 4,072,453 bytes in 11,312 blocks ==31875== suppressed: 0 bytes in 0 blocks ==31875== Rerun with --leak-check=full to see details of leaked memory ==31875== ==31875== For counts of detected and suppressed errors, rerun with: -v ==31875== ERROR SUMMARY: 1 errors from 1 contexts (suppressed: 2 from 2)