[Gambas-user] Issue 204 in gambas: [gb.dbus] A memory leaks in the handling of errors when calling the dbus
gambas at ...2524...
gambas at ...2524...
Sat Jan 21 14:11:30 CET 2012
Status: New
Owner: ----
Labels: Version Type-Bug Priority-Medium OpSys-Any Dist-Any Arch-Any
Desktop-Any GUI-Any
New issue 204 by svit... at ...626...: [gb.dbus] A memory leaks in the
handling of errors when calling the dbus
http://code.google.com/p/gambas/issues/detail?id=204
1) Describe the problem.
subj
2) GIVE THE FOLLOWING INFORMATIONS (if they are appropriate):
Version: TRUNK
Revision: r4413
Operating system: any
Distribution: any
Architecture: any
GUI component: any
Desktop used: any
3) Provide a little project that reproduces the bug or the crash.
attached
4) If your project needs a database, try to provide it, or part of it.
none
5) Explain clearly how to reproduce the bug or the crash.
run:
valgrind gbx3
/home/my/Devel/Gambas/3/probe/bug-gb.dbus-error-handle-memory-leaks.gambas
output:
valgrind gbr3
/home/my/Devel/Gambas/3/probe/bug-gb.dbus-error-handle-memory-leaks.gambas
==32605== Memcheck, a memory error detector
==32605== Copyright (C) 2002-2010, and GNU GPL'd, by Julian Seward et al.
==32605== Using Valgrind-3.6.1 and LibVEX; rerun with -h for copyright info
==32605== Command: gbr3
/home/my/Devel/Gambas/3/probe/bug-gb.dbus-error-handle-memory-leaks.gambas
==32605==
==32605==
==32605== HEAP SUMMARY:
==32605== in use at exit: 22,266 bytes in 78 blocks
==32605== total heap usage: 1,036 allocs, 958 frees, 153,875 bytes
allocated
==32605==
==32605== LEAK SUMMARY:
==32605== definitely lost: 61 bytes in 2 blocks
==32605== indirectly lost: 0 bytes in 0 blocks
==32605== possibly lost: 0 bytes in 0 blocks
==32605== still reachable: 22,205 bytes in 76 blocks
==32605== suppressed: 0 bytes in 0 blocks
==32605== Rerun with --leak-check=full to see details of leaked memory
==32605==
==32605== For counts of detected and suppressed errors, rerun with: -v
==32605== ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 27 from 10)
6) Workaround
Need to add a call dbus_error_free (&error) in the error handler.
Attachments:
bug-gb.dbus-error-handle-memory-leaks-0.0.3.tar.gz 4.5 KB
More information about the User
mailing list