segfault-t failing under recent AddressSanitizer

Bug #1676847 reported by Laurynas Biveinis
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
MySQL Server
Unknown
Unknown
Percona Server moved to https://jira.percona.com/projects/PS
Status tracked in 5.7
5.5
Invalid
Undecided
Unassigned
5.6
Fix Released
Low
Laurynas Biveinis
5.7
Fix Released
Low
Laurynas Biveinis

Bug Description

Copy of https://bugs.mysql.com/bug.php?id=85671:

[28 Mar 11:43] Laurynas Biveinis
Description:
5.6.35 on Ubuntu Yakkety, GCC compiler with ASan:

unittest/gunit/merge_large_tests-t
...
# Run 3 FatalSignalDeathTest.Segfault
/home/laurynas/mysql-server/unittest/gunit/segfault-t.cc:66: FailureDeath test: *pint= 42
    Result: died but not with expected error.
  Expected: .*ASAN:SIGSEGV.*
Actual msg:
[ DEATH ] ASAN:DEADLYSIGNAL
[ DEATH ] =================================================================
[ DEATH ] ==8818==ERROR: AddressSanitizer: SEGV on unknown address 0x000000000000 (pc 0x5564895c0b0f bp 0x7fff12e59450 sp 0x7fff12e59280 T0)
[ DEATH ] #0 0x5564895c0b0e in segfault_unittest::FatalSignalDeathTest_Segfault_Test::TestBody() /home/laurynas/mysql-server/unittest/gunit/segfault-t.cc:66
[ DEATH ] #1 0x55648aa755c1 in void testing::internal::HandleSehExceptionsInMethodIfSupported<testing::Test, void>(testing::Test*, void (testing::Test::*)(), char const*) /home/laurynas/mysql-server/source_downloads/googletest-release-1.8.0/googletest/src/gtest.cc:2402
[ DEATH ] #2 0x55648aa755c1 in void testing::internal::HandleExceptionsInMethodIfSupported<testing::Test, void>(testing::Test*, void (testing::Test::*)(), char const*) /home/laurynas/mysql-server/source_downloads/googletest-release-1.8.0/googletest/src/gtest.cc:2438
[ DEATH ] #3 0x55648aa6263e in testing::Test::Run() /home/laurynas/mysql-server/source_downloads/googletest-release-1.8.0/googletest/src/gtest.cc:2475
[ DEATH ] #4 0x55648aa628db in testing::TestInfo::Run() /home/laurynas/mysql-server/source_downloads/googletest-release-1.8.0/googletest/src/gtest.cc:2656
[ DEATH ] #5 0x55648aa62a62 in testing::TestCase::Run() /home/laurynas/mysql-server/source_downloads/googletest-release-1.8.0/googletest/src/gtest.cc:2774
[ DEATH ] #6 0x55648aa62fb0 in testing::internal::UnitTestImpl::RunAllTests() /home/laurynas/mysql-server/source_downloads/googletest-release-1.8.0/googletest/src/gtest.cc:4649
[ DEATH ] #7 0x55648aa76144 in bool testing::internal::HandleSehExceptionsInMethodIfSupported<testing::internal::UnitTestImpl, bool>(testing::internal::UnitTestImpl*, bool (testing::internal::UnitTestImpl::*)(), char const*) /home/laurynas/mysql-server/source_downloads/googletest-release-1.8.0/googletest/src/gtest.cc:2402
[ DEATH ] #8 0x55648aa76144 in bool testing::internal::HandleExceptionsInMethodIfSupported<testing::internal::UnitTestImpl, bool>(testing::internal::UnitTestImpl*, bool (testing::internal::UnitTestImpl::*)(), char const*) /home/laurynas/mysql-server/source_downloads/googletest-release-1.8.0/googletest/src/gtest.cc:2438
[ DEATH ] #9 0x55648aa6376c in testing::UnitTest::Run() /home/laurynas/mysql-server/source_downloads/googletest-release-1.8.0/googletest/src/gtest.cc:4257
[ DEATH ] #10 0x55648a14637b in RUN_ALL_TESTS() /home/laurynas/mysql-server/source_downloads/googletest-release-1.8.0/googletest/include/gtest/gtest.h:2233
[ DEATH ] #11 0x55648a14637b in main /home/laurynas/mysql-server/unittest/gunit/gunit_test_main_server.cc:72
[ DEATH ] #12 0x7f2f909f03f0 in __libc_start_main (/lib/x86_64-linux-gnu/libc.so.6+0x203f0)
[ DEATH ] #13 0x556489563569 in _start (/home/laurynas/obj-percona-5.6-asan-debug/unittest/gunit/merge_large_tests-t+0x671569)
[ DEATH ]
[ DEATH ] AddressSanitizer can not provide additional info.
[ DEATH ] SUMMARY: AddressSanitizer: SEGV /home/laurynas/mysql-server/unittest/gunit/segfault-t.cc:66 in segfault_unittest::FatalSignalDeathTest_Segfault_Test::TestBody()
[ DEATH ] ==8818==ABORTING
[ DEATH ]
not ok 3

How to repeat:
See above

Suggested fix:
Looks like both "ASAN:SIGSEGV" and "ASAN:DEADLYSIGNAL" should be expected

Tags: asan ci upstream
tags: added: asan ci upstream
Revision history for this message
Laurynas Biveinis (laurynas-biveinis) wrote :
Revision history for this message
Shahriyar Rzayev (rzayev-sehriyar) wrote :

Percona now uses JIRA for bug reports so this bug report is migrated to: https://jira.percona.com/browse/PS-2252

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.