[NeoStats-Devel] Valgrind report on TriviaServ

"Justin Hammond" <justin-kLev/[email protected]> Wed, 31 Aug 2005 21:12:16 +0800
Newsgroups gmane.comp.neostats.devel
Message-ID <[email protected]>
DNB, 
As promised here is the valgrind report for TriviaServ. I've removed all the
other errors not directly related to TriviaServ.

If you have any questions about the actual error reported, just ask. :)

Thanks


--11178-- discard syms at 0x1BEB7000-0x1BEC2000 in
/lib/libnss_files-2.3.2.so due to munmap()
==11178== 
==11178== ERROR SUMMARY: 213 errors from 5 contexts (suppressed: 54 from 1)
==11178== 
==11178== 3 errors in context 1 of 5:
==11178== Invalid write of size 1
==11178==    at 0x1BFC916B: obscure_question (TriviaQues.c:676)
==11178==    by 0x1BFC84F3: tvs_newquest (TriviaQues.c:356)
==11178==    by 0x1BFC5E7E: tvs_processtimer (TriviaServ.c:427)
==11178==    by 0x806C544: run_mod_timers (timer.c:444)
==11178==    by 0x806BF04: CheckTimers_cb (timer.c:143)
==11178==    by 0x80876F7: event_process_active (event.c:287)
==11178==    by 0x80878F1: event_base_loop (event.c:401)
==11178==    by 0x808778F: event_loop (event.c:336)
==11178==    by 0x806AA9B: read_loop (sock.c:152)
==11178==    by 0x8066BC8: main (main.c:451)
==11178==  Address 0x1CC50208 is 7 bytes after a block of size 513 alloc'd
==11178==    at 0x1B8FFD0F: calloc (vg_replace_malloc.c:279)
==11178==    by 0x806FCE3: ns_calloc (nsmemory.c:79)
==11178==    by 0x1BFC8FC9: obscure_question (TriviaQues.c:662)
==11178==    by 0x1BFC84F3: tvs_newquest (TriviaQues.c:356)
==11178==    by 0x1BFC5E7E: tvs_processtimer (TriviaServ.c:427)
==11178==    by 0x806C544: run_mod_timers (timer.c:444)
==11178==    by 0x806BF04: CheckTimers_cb (timer.c:143)
==11178==    by 0x80876F7: event_process_active (event.c:287)
==11178==    by 0x80878F1: event_base_loop (event.c:401)
==11178==    by 0x808778F: event_loop (event.c:336)
==11178==    by 0x806AA9B: read_loop (sock.c:152)
==11178==    by 0x8066BC8: main (main.c:451)
==11178== 
==11178== 4 errors in context 2 of 5:
==11178== Syscall param write(buf) points to uninitialised byte(s)
==11178==    at 0x1BB90B53: __write_nocancel (in
/lib/tls/libpthread-0.60.so)
==11178==    by 0x1B93453B: DBMOpenTable (gdbm.c:40)
==11178==    by 0x805D1DF: DBAOpenTable (nsdba.c:263)
==11178==    by 0x805D306: DBAFetchTableEntry (nsdba.c:300)
==11178==    by 0x805D512: DBAFetchRows (nsdba.c:403)
==11178==    by 0x1BFC5D17: tvs_get_settings (TriviaServ.c:400)
==11178==    by 0x1BFC5A6A: ModInit (TriviaServ.c:209)
==11178==    by 0x8067FE6: load_stdmodule (modules.c:345)
==11178==    by 0x8068226: ns_load_module (modules.c:398)
==11178==    by 0x805DB53: ConfLoadModules (conf.c:327)
==11178==    by 0x8066BBE: main (main.c:448)
==11178==  Address 0x1BFA9788 is 56 bytes inside a block of size 4096
alloc'd
==11178==    at 0x1B8FEA55: malloc (vg_replace_malloc.c:149)
==11178==    by 0x1B93665D: gdbm_open (gdbmopen.c:214)
==11178==    by 0x1B93453B: DBMOpenTable (gdbm.c:40)
==11178==    by 0x805D1DF: DBAOpenTable (nsdba.c:263)
==11178==    by 0x805D306: DBAFetchTableEntry (nsdba.c:300)
==11178==    by 0x805D512: DBAFetchRows (nsdba.c:403)
==11178==    by 0x1BFC5D17: tvs_get_settings (TriviaServ.c:400)
==11178==    by 0x1BFC5A6A: ModInit (TriviaServ.c:209)
==11178==    by 0x8067FE6: load_stdmodule (modules.c:345)
==11178==    by 0x8068226: ns_load_module (modules.c:398)
==11178==    by 0x805DB53: ConfLoadModules (conf.c:327)
==11178==    by 0x8066BBE: main (main.c:448)
==11178== 
==11178== 16 errors in context 3 of 5:
==11178== Invalid write of size 1
==11178==    at 0x1BFC905C: obscure_question (TriviaQues.c:684)
==11178==    by 0x1BFC84F3: tvs_newquest (TriviaQues.c:356)
==11178==    by 0x1BFC5E7E: tvs_processtimer (TriviaServ.c:427)
==11178==    by 0x806C544: run_mod_timers (timer.c:444)
==11178==    by 0x806BF04: CheckTimers_cb (timer.c:143)
==11178==    by 0x80876F7: event_process_active (event.c:287)
==11178==    by 0x80878F1: event_base_loop (event.c:401)
==11178==    by 0x808778F: event_loop (event.c:336)
==11178==    by 0x806AA9B: read_loop (sock.c:152)
==11178==    by 0x8066BC8: main (main.c:451)
==11178==  Address 0x1CC50201 is 0 bytes after a block of size 513 alloc'd
==11178==    at 0x1B8FFD0F: calloc (vg_replace_malloc.c:279)
==11178==    by 0x806FCE3: ns_calloc (nsmemory.c:79)
==11178==    by 0x1BFC8FC9: obscure_question (TriviaQues.c:662)
==11178==    by 0x1BFC84F3: tvs_newquest (TriviaQues.c:356)
==11178==    by 0x1BFC5E7E: tvs_processtimer (TriviaServ.c:427)
==11178==    by 0x806C544: run_mod_timers (timer.c:444)
==11178==    by 0x806BF04: CheckTimers_cb (timer.c:143)
==11178==    by 0x80876F7: event_process_active (event.c:287)
==11178==    by 0x80878F1: event_base_loop (event.c:401)
==11178==    by 0x808778F: event_loop (event.c:336)
==11178==    by 0x806AA9B: read_loop (sock.c:152)
==11178==    by 0x8066BC8: main (main.c:451)
==11178== 
==11178== 36 errors in context 4 of 5:
==11178== Invalid read of size 1
==11178==    at 0x1BFC9164: obscure_question (TriviaQues.c:676)
==11178==    by 0x1BFC84F3: tvs_newquest (TriviaQues.c:356)
==11178==    by 0x1BFC5E7E: tvs_processtimer (TriviaServ.c:427)
==11178==    by 0x806C544: run_mod_timers (timer.c:444)
==11178==    by 0x806BF04: CheckTimers_cb (timer.c:143)
==11178==    by 0x80876F7: event_process_active (event.c:287)
==11178==    by 0x80878F1: event_base_loop (event.c:401)
==11178==    by 0x808778F: event_loop (event.c:336)
==11178==    by 0x806AA9B: read_loop (sock.c:152)
==11178==    by 0x8066BC8: main (main.c:451)
==11178==  Address 0x1CC50201 is 0 bytes after a block of size 513 alloc'd
==11178==    at 0x1B8FFD0F: calloc (vg_replace_malloc.c:279)
==11178==    by 0x806FCE3: ns_calloc (nsmemory.c:79)
==11178==    by 0x1BFC8FC9: obscure_question (TriviaQues.c:662)
==11178==    by 0x1BFC84F3: tvs_newquest (TriviaQues.c:356)
==11178==    by 0x1BFC5E7E: tvs_processtimer (TriviaServ.c:427)
==11178==    by 0x806C544: run_mod_timers (timer.c:444)
==11178==    by 0x806BF04: CheckTimers_cb (timer.c:143)
==11178==    by 0x80876F7: event_process_active (event.c:287)
==11178==    by 0x80878F1: event_base_loop (event.c:401)
==11178==    by 0x808778F: event_loop (event.c:336)
==11178==    by 0x806AA9B: read_loop (sock.c:152)
==11178==    by 0x8066BC8: main (main.c:451)
==11178== 
==11178== 154 errors in context 5 of 5:
==11178== Invalid read of size 1
==11178==    at 0x1BFC911D: obscure_question (TriviaQues.c:691)
==11178==    by 0x1BFC84F3: tvs_newquest (TriviaQues.c:356)
==11178==    by 0x1BFC5E7E: tvs_processtimer (TriviaServ.c:427)
==11178==    by 0x806C544: run_mod_timers (timer.c:444)
==11178==    by 0x806BF04: CheckTimers_cb (timer.c:143)
==11178==    by 0x80876F7: event_process_active (event.c:287)
==11178==    by 0x80878F1: event_base_loop (event.c:401)
==11178==    by 0x808778F: event_loop (event.c:336)
==11178==    by 0x806AA9B: read_loop (sock.c:152)
==11178==    by 0x8066BC8: main (main.c:451)
==11178==  Address 0x1CC50201 is 0 bytes after a block of size 513 alloc'd
==11178==    at 0x1B8FFD0F: calloc (vg_replace_malloc.c:279)
==11178==    by 0x806FCE3: ns_calloc (nsmemory.c:79)
==11178==    by 0x1BFC8FC9: obscure_question (TriviaQues.c:662)
==11178==    by 0x1BFC84F3: tvs_newquest (TriviaQues.c:356)
==11178==    by 0x1BFC5E7E: tvs_processtimer (TriviaServ.c:427)
==11178==    by 0x806C544: run_mod_timers (timer.c:444)
==11178==    by 0x806BF04: CheckTimers_cb (timer.c:143)
==11178==    by 0x80876F7: event_process_active (event.c:287)
==11178==    by 0x80878F1: event_base_loop (event.c:401)
==11178==    by 0x808778F: event_loop (event.c:336)
==11178==    by 0x806AA9B: read_loop (sock.c:152)
==11178==    by 0x8066BC8: main (main.c:451)
--11178-- 
--11178-- supp:   54 Ugly strchr error in /lib/ld-2.3.2.so
==11178== 
==11178== IN SUMMARY: 213 errors from 5 contexts (suppressed: 54 from 1)
==11178== 
==11178== malloc/free: in use at exit: 3468941 bytes in 151617 blocks.
==11178== malloc/free: 154462 allocs, 2845 frees, 7360964 bytes allocated.
==11178== 
==11178== searching for pointers to 151617 not-freed blocks.
==11178== checked 4104812 bytes.
==11178== 
==11178== 
==11178== 2136 bytes in 56 blocks are indirectly lost in loss record 8 of 19
==11178==    at 0x1B8FEA55: malloc (vg_replace_malloc.c:149)
==11178==    by 0x1BC3AE45: scandir64@@GLIBC_2.2 (in /lib/tls/libc-2.3.2.so)
==11178==    by 0x1BFC5CEF: tvs_get_settings (TriviaServ.c:373)
==11178==    by 0x1BFC5A6A: ModInit (TriviaServ.c:209)
==11178==    by 0x8067FE6: load_stdmodule (modules.c:345)
==11178==    by 0x8068226: ns_load_module (modules.c:398)
==11178==    by 0x805DB53: ConfLoadModules (conf.c:327)
==11178==    by 0x8066BBE: main (main.c:448)
==11178== 
==11178== 
==11178== 2456 (320 direct, 2136 indirect) bytes in 1 blocks are definitely
lost in loss record 9 of 19
==11178==    at 0x1B8FFDEF: realloc (vg_replace_malloc.c:306)
==11178==    by 0x1BC3AF74: scandir64@@GLIBC_2.2 (in /lib/tls/libc-2.3.2.so)
==11178==    by 0x1BFC5CEF: tvs_get_settings (TriviaServ.c:373)
==11178==    by 0x1BFC5A6A: ModInit (TriviaServ.c:209)
==11178==    by 0x8067FE6: load_stdmodule (modules.c:345)
==11178==    by 0x8068226: ns_load_module (modules.c:398)
==11178==    by 0x805DB53: ConfLoadModules (conf.c:327)
==11178==    by 0x8066BBE: main (main.c:448)
==11178== 
==11178== 
==11178== 48792 (40 direct, 48752 indirect) bytes in 2 blocks are definitely
lost in loss record 11 of 19
==11178==    at 0x1B8FEA55: malloc (vg_replace_malloc.c:149)
==11178==    by 0x806FC89: ns_malloc (nsmemory.c:50)
==11178==    by 0x8064FCD: list_create (list.c:97)
==11178==    by 0x1BFC5D5E: tvs_get_settings (TriviaServ.c:397)
==11178==    by 0x1BFC5A6A: ModInit (TriviaServ.c:209)
==11178==    by 0x8067FE6: load_stdmodule (modules.c:345)
==11178==    by 0x8068226: ns_load_module (modules.c:398)
==11178==    by 0x805DB53: ConfLoadModules (conf.c:327)
==11178==    by 0x8066BBE: main (main.c:448)
==11178== 
==11178== 
==11178== 989 (32 direct, 957 indirect) bytes in 1 blocks are definitely
lost in loss record 13 of 19
==11178==    at 0x1B8FFD0F: calloc (vg_replace_malloc.c:279)
==11178==    by 0x806FCE3: ns_calloc (nsmemory.c:79)
==11178==    by 0x1BFC83FC: tvs_newquest (TriviaQues.c:328)
==11178==    by 0x1BFC5E7E: tvs_processtimer (TriviaServ.c:427)
==11178==    by 0x806C544: run_mod_timers (timer.c:444)
==11178==    by 0x806BF04: CheckTimers_cb (timer.c:143)
==11178==    by 0x80876F7: event_process_active (event.c:287)
==11178==    by 0x80878F1: event_base_loop (event.c:401)
==11178==    by 0x808778F: event_loop (event.c:336)
==11178==    by 0x806AA9B: read_loop (sock.c:152)
==11178==    by 0x8066BC8: main (main.c:451)
==11178== 
==11178== 
==11178== 57 bytes in 1 blocks are indirectly lost in loss record 14 of 19
==11178==    at 0x1B8FEA55: malloc (vg_replace_malloc.c:149)
==11178==    by 0x1B905E35: pcre_compile (pcre.c:4668)
==11178==    by 0x1BFC8908: tvs_doregex (TriviaQues.c:442)
==11178==    by 0x1BFC84B0: tvs_newquest (TriviaQues.c:344)
==11178==    by 0x1BFC5E7E: tvs_processtimer (TriviaServ.c:427)
==11178==    by 0x806C544: run_mod_timers (timer.c:444)
==11178==    by 0x806BF04: CheckTimers_cb (timer.c:143)
==11178==    by 0x80876F7: event_process_active (event.c:287)
==11178==    by 0x80878F1: event_base_loop (event.c:401)
==11178==    by 0x808778F: event_loop (event.c:336)
==11178==    by 0x806AA9B: read_loop (sock.c:152)
==11178==    by 0x8066BC8: main (main.c:451)
==11178== 
==11178== 
==11178== 13296 bytes in 1108 blocks are indirectly lost in loss record 15
of 19
==11178==    at 0x1B8FEA55: malloc (vg_replace_malloc.c:149)
==11178==    by 0x806FC89: ns_malloc (nsmemory.c:50)
==11178==    by 0x8065460: lnode_create (list.c:260)
==11178==    by 0x8065F8E: lnode_create_append (list.c:867)
==11178==    by 0x1BFC7D63: tvs_parse_questions (TriviaQues.c:90)
==11178==    by 0x1BFC5A7A: ModInit (TriviaServ.c:211)
==11178==    by 0x8067FE6: load_stdmodule (modules.c:345)
==11178==    by 0x8068226: ns_load_module (modules.c:398)
==11178==    by 0x805DB53: ConfLoadModules (conf.c:327)
==11178==    by 0x8066BBE: main (main.c:448)
==11178== 
==11178== 
==11178== 19008 bytes in 54 blocks are still reachable in loss record 16 of
19
==11178==    at 0x1B8FEA55: malloc (vg_replace_malloc.c:149)
==11178==    by 0x1BBF5D1E: __fopen_internal (in /lib/tls/libc-2.3.2.so)
==11178==    by 0x1BBF855B: fopen64 (in /lib/tls/libc-2.3.2.so)
==11178==    by 0x8079201: os_fopen (osfile.c:97)
==11178==    by 0x1BFC7BF6: tvs_parse_questions (TriviaQues.c:51)
==11178==    by 0x1BFC5A7A: ModInit (TriviaServ.c:211)
==11178==    by 0x8067FE6: load_stdmodule (modules.c:345)
==11178==    by 0x8068226: ns_load_module (modules.c:398)
==11178==    by 0x805DB53: ConfLoadModules (conf.c:327)
==11178==    by 0x8066BBE: main (main.c:448)
==11178== 
==11178== 
==11178== 36356 bytes in 1111 blocks are indirectly lost in loss record 17
of 19
==11178==    at 0x1B8FFD0F: calloc (vg_replace_malloc.c:279)
==11178==    by 0x806FCE3: ns_calloc (nsmemory.c:79)
==11178==    by 0x1BFC7D1B: tvs_parse_questions (TriviaQues.c:81)
==11178==    by 0x1BFC5A7A: ModInit (TriviaServ.c:211)
==11178==    by 0x8067FE6: load_stdmodule (modules.c:345)
==11178==    by 0x8068226: ns_load_module (modules.c:398)
==11178==    by 0x805DB53: ConfLoadModules (conf.c:327)
==11178==    by 0x8066BBE: main (main.c:448)

==11178==

==11178== 
==11178== 2495356 bytes in 74598 blocks are still reachable in loss record
19 of 19
==11178==    at 0x1B8FFD0F: calloc (vg_replace_malloc.c:279)
==11178==    by 0x806FCE3: ns_calloc (nsmemory.c:79)
==11178==    by 0x1BFC5D34: tvs_get_settings (TriviaServ.c:391)
==11178==    by 0x1BFC5A6A: ModInit (TriviaServ.c:209)
==11178==    by 0x8067FE6: load_stdmodule (modules.c:345)
==11178==    by 0x8068226: ns_load_module (modules.c:398)
==11178==    by 0x805DB53: ConfLoadModules (conf.c:327)
==11178==    by 0x8066BBE: main (main.c:448)
==11178== 
==11178== LEAK SUMMARY:
==11178==    definitely lost: 392 bytes in 4 blocks.
==11178==    indirectly lost: 51845 bytes in 2276 blocks.
==11178==      possibly lost: 0 bytes in 0 blocks.
==11178==    still reachable: 3411896 bytes in 149308 blocks.
==11178==         suppressed: 4808 bytes in 29 blocks.