Description:
A testsuite run shows unit test failure:
...
unit_tests w0 [ fail ]
...
Digging deeper, it is explain_filename that fails:
obj$ make test
Running tests...
Test project /home/laurynas/percona/src/5.5/obj
Start 1: pfs_instr_class
1/14 Test #1: pfs_instr_class .................. Passed 0.00 sec
Start 2: pfs_instr_class-oom
2/14 Test #2: pfs_instr_class-oom .............. Passed 0.00 sec
Start 3: pfs_instr
3/14 Test #3: pfs_instr ........................ Passed 0.00 sec
Start 4: pfs_instr-oom
4/14 Test #4: pfs_instr-oom .................... Passed 0.00 sec
Start 5: pfs
5/14 Test #5: pfs .............................. Passed 0.60 sec
Start 6: bitmap
6/14 Test #6: bitmap ........................... Passed 4.35 sec
Start 7: base64
7/14 Test #7: base64 ........................... Passed 0.03 sec
Start 8: my_vsnprintf
8/14 Test #8: my_vsnprintf ..................... Passed 0.00 sec
Start 9: my_atomic
9/14 Test #9: my_atomic ........................ Passed 2.01 sec
Start 10: my_rdtsc
10/14 Test #10: my_rdtsc ......................... Passed 0.12 sec
Start 11: lf
11/14 Test #11: lf ............................... Passed 2.25 sec
Start 12: my_malloc
12/14 Test #12: my_malloc ........................ Passed 0.00 sec
Start 13: explain_filename
13/14 Test #13: explain_filename .................***Failed 0.01 sec
Start 14: my_decimal
14/14 Test #14: my_decimal ....................... Passed 0.00 sec
93% tests passed, 1 tests failed out of 14
Total Test time (real) = 9.42 sec
The following tests FAILED:
13 - explain_filename (Failed)
Errors while running CTest
make: *** [test] Error 8
$ cd unittest/mysys/
$ ./explain_filename-t
1..22
Bail out! Signal 11 thrown
$ valgrind ./explain_filename-t
==25825== Memcheck, a memory error detector
==25825== Copyright (C) 2002-2012, and GNU GPL'd, by Julian Seward et al.
==25825== Using Valgrind-3.8.1 and LibVEX; rerun with -h for copyright info
==25825== Command: ./explain_filename-t
==25825==
1..22
==25825== Invalid read of size 4
==25825== at 0xA3C869: _db_enter_ (dbug.c:1112)
==25825== by 0x55DB75: explain_filename(THD*, char const*, char*, unsigned int, enum_explain_filename_mode) (sql_table.cc:214)
==25825== by 0x43A897: test_1(char const*, char const*, enum_explain_filename_mode) (explain_filename-t.cc:53)
==25825== by 0x43A976: main (explain_filename-t.cc:71)
==25825== Address 0x35 is not stack'd, malloc'd or (recently) free'd
==25825==
Bail out! Signal 11 thrown
==25825==
==25825== HEAP SUMMARY:
==25825== in use at exit: 32 bytes in 1 blocks
==25825== total heap usage: 15 allocs, 14 frees, 14,592 bytes allocated
==25825==
==25825== LEAK SUMMARY:
==25825== definitely lost: 0 bytes in 0 blocks
==25825== indirectly lost: 0 bytes in 0 blocks
==25825== possibly lost: 0 bytes in 0 blocks
==25825== still reachable: 32 bytes in 1 blocks
==25825== suppressed: 0 bytes in 0 blocks
==25825== Rerun with --leak-check=full to see details of leaked memory
==25825==
==25825== For counts of detected and suppressed errors, rerun with: -v
==25825== ERROR SUMMARY: 1 errors from 1 contexts (suppressed: 0 from 0)
How to repeat:
cmake -DWITH_DEBUG=ON, make, explain_filename-t
Suggested fix:
Investigating.
Description: A testsuite run shows unit test failure: ... unit_tests w0 [ fail ] ... Digging deeper, it is explain_filename that fails: obj$ make test Running tests... Test project /home/laurynas/percona/src/5.5/obj Start 1: pfs_instr_class 1/14 Test #1: pfs_instr_class .................. Passed 0.00 sec Start 2: pfs_instr_class-oom 2/14 Test #2: pfs_instr_class-oom .............. Passed 0.00 sec Start 3: pfs_instr 3/14 Test #3: pfs_instr ........................ Passed 0.00 sec Start 4: pfs_instr-oom 4/14 Test #4: pfs_instr-oom .................... Passed 0.00 sec Start 5: pfs 5/14 Test #5: pfs .............................. Passed 0.60 sec Start 6: bitmap 6/14 Test #6: bitmap ........................... Passed 4.35 sec Start 7: base64 7/14 Test #7: base64 ........................... Passed 0.03 sec Start 8: my_vsnprintf 8/14 Test #8: my_vsnprintf ..................... Passed 0.00 sec Start 9: my_atomic 9/14 Test #9: my_atomic ........................ Passed 2.01 sec Start 10: my_rdtsc 10/14 Test #10: my_rdtsc ......................... Passed 0.12 sec Start 11: lf 11/14 Test #11: lf ............................... Passed 2.25 sec Start 12: my_malloc 12/14 Test #12: my_malloc ........................ Passed 0.00 sec Start 13: explain_filename 13/14 Test #13: explain_filename .................***Failed 0.01 sec Start 14: my_decimal 14/14 Test #14: my_decimal ....................... Passed 0.00 sec 93% tests passed, 1 tests failed out of 14 Total Test time (real) = 9.42 sec The following tests FAILED: 13 - explain_filename (Failed) Errors while running CTest make: *** [test] Error 8 $ cd unittest/mysys/ $ ./explain_filename-t 1..22 Bail out! Signal 11 thrown $ valgrind ./explain_filename-t ==25825== Memcheck, a memory error detector ==25825== Copyright (C) 2002-2012, and GNU GPL'd, by Julian Seward et al. ==25825== Using Valgrind-3.8.1 and LibVEX; rerun with -h for copyright info ==25825== Command: ./explain_filename-t ==25825== 1..22 ==25825== Invalid read of size 4 ==25825== at 0xA3C869: _db_enter_ (dbug.c:1112) ==25825== by 0x55DB75: explain_filename(THD*, char const*, char*, unsigned int, enum_explain_filename_mode) (sql_table.cc:214) ==25825== by 0x43A897: test_1(char const*, char const*, enum_explain_filename_mode) (explain_filename-t.cc:53) ==25825== by 0x43A976: main (explain_filename-t.cc:71) ==25825== Address 0x35 is not stack'd, malloc'd or (recently) free'd ==25825== Bail out! Signal 11 thrown ==25825== ==25825== HEAP SUMMARY: ==25825== in use at exit: 32 bytes in 1 blocks ==25825== total heap usage: 15 allocs, 14 frees, 14,592 bytes allocated ==25825== ==25825== LEAK SUMMARY: ==25825== definitely lost: 0 bytes in 0 blocks ==25825== indirectly lost: 0 bytes in 0 blocks ==25825== possibly lost: 0 bytes in 0 blocks ==25825== still reachable: 32 bytes in 1 blocks ==25825== suppressed: 0 bytes in 0 blocks ==25825== Rerun with --leak-check=full to see details of leaked memory ==25825== ==25825== For counts of detected and suppressed errors, rerun with: -v ==25825== ERROR SUMMARY: 1 errors from 1 contexts (suppressed: 0 from 0) How to repeat: cmake -DWITH_DEBUG=ON, make, explain_filename-t Suggested fix: Investigating.