DynamoRIO / DynamoRIO/drmemory
false positive possible leaks in mingw gtk3-demo from glib malloc?
- Dominant language
- C
- Stars
- 2.7k
- Forks
- 290
- PR merge metrics
- No merged PRs in 30d
Description
_From [bruen...@google.com](https://code.google.com/u/109494838902877177630/) on February 21, 2013 23:13:43_
running mingw gtk3-demo (xref issue #1046 ) there are some uninits that are
probably false positives, and a lot of possible leaks:
~~Dr.M~~ ERRORS FOUND:
~~Dr.M~~ 1 unique, 1 total unaddressable access(es)
~~Dr.M~~ 40 unique, 505 total uninitialized access(es)
~~Dr.M~~ 0 unique, 0 total invalid heap argument(s)
~~Dr.M~~ 4 unique, 38 total GDI usage error(s)
~~Dr.M~~ 0 unique, 0 total warning(s)
~~Dr.M~~ 21 unique, 62 total, 7693 byte(s) of leak(s)
~~Dr.M~~ 355 unique, 379 total, 16450 byte(s) of possible leak(s)
~~Dr.M~~ ERRORS IGNORED:
~~Dr.M~~ 12796 still-reachable allocation(s)
~~Dr.M~~ (re-run with "-show_reachable" for details)
most are like this:
Error `#414`: POSSIBLE LEAK 36 direct bytes 0x01ff0e70-0x01ff0e94 + 0 indirect bytes
#0 libglib-2.0-0.dll!g_malloc0 [../../glib/gmem.c:189]
#1 libgobject-2.0-0.dll!g_closure_new_simple [../../gobject/gclosure.c:206]
#2 libgobject-2.0-0.dll!g_cclosure_new [../../gobject/gclosure.c:917]
#3 libgobject-2.0-0.dll!g_signal_new_class_handler [../../gobject/gsignal.c:1480]
#4 libgtk-3-0.dll!gtk_text_view_class_intern_init [../../gtk/gtktextview.c:929]
#5 libgobject-2.0-0.dll!g_type_class_ref [../../gobject/gtype.c:2239]
#6 libgobject-2.0-0.dll!g_object_newv [../../gobject/gobject.c:1624]
#7 __tmainCRTStartup [../crt/crtexe.c:315]
#8 KERNEL32.dll!BaseThreadInitThunk
#9 ntdll.dll!__RtlUserThreadStart
I suspect glib's extra layer is involved here.
logs are attached.
logs are in ~/drmemory/bugs/i1046-gtk/DrMemory-gtk3-demo.exe.7948.000/
and /work/drmemory/bugs/i1046-gtk/DrMemory-gtk3-demo.exe.7948.000/
_Original issue: http://code.google.com/p/drmemory/issues/detail?id=1143_
Contributor guide
Research direction
Start by reading the attached Dr. Memory logs at ~/drmemory/bugs/i1046-gtk/DrMemory-gtk3-demo.exe.7948.000/ and /work/drmemory/bugs/i1046-gtk/DrMemory-gtk3-demo.exe.7948.000/. Trace the reported g_malloc0, g_closure_new_simple, g_cclosure_new, and gtk_text_view_class_intern_init entries in the shown stack, then establish whether the GTK3 demo reports are false positives and document or reproduce the result.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- c
- Domain
- testing, tooling
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100