|
From: Philippe W. <phi...@sk...> - 2013-10-09 20:24:24
|
On Tue, 2013-10-08 at 23:27 +0200, Matthias Schwarzott wrote: > Hi Philippe, > > the client request leak_check shows an error. > lcp.heuristics is not initialized correctly in mc_handle_client_request. Thanks for the report, fixed in revision 13631. > >==29370== Searching for pointers to 8 not-freed blocks > ==29370== Conditional jump or move depends on uninitialised value(s) > ==29370== at 0x28000D61: lc_push_without_clique_if_a_chunk_ptr > (mc_leakcheck.c:825) > ==29370== by 0x28000F38: lc_scan_memory (mc_leakcheck.c:913) > ==29370== by 0x2800131C: scan_memory_root_set (mc_leakcheck.c:1630) > ==29370== by 0x28001B9C: vgMemCheck_detect_memory_leaks > (mc_leakcheck.c:1784) > ==29370== by 0x2800FCB1: mc_handle_client_request (mc_main.c:5546) > ==29370== by 0x2808092B: handle_gdb_monitor_command (server.c:474) > ==29370== by 0x280811A3: vgPlain_client_monitor_command (server.c:535) > ==29370== by 0x28088D2E: vgPlain_scheduler (scheduler.c:1963) > ==29370== by 0x2809B06E: run_a_thread_NORETURN (syswrap-linux.c:103) Not too sure what is the SVN version which produces the above stack trace. I think there are two different problems: one is the leak check heusistic parameter (fixed by the above revision, the other is the fact that the heuristic code itself should verify the definedness of the pointed to data before using it to decide of heuristic reachdness. For example, for newarray heuristic, if the first word is not (fully) defined, the heuristic should not consider that this chunk is reachable via the heuristic. (still need to fix this) > > Currently a random set of heuristics is enabled when triggering leak_check. > The question is: What should be the default value of heuristics, when > not specified. Basically, there would be 3 choices: none use the command line value given by the user all none chosen because this ensures a backward compatible behaviour. Philippe |