Fixed #2425 (segmentation fault of cppcheck)
This commit is contained in:
parent
9b66f7a754
commit
5f078da7ad
|
@ -184,6 +184,7 @@ private:
|
|||
TEST_CASE(symboldatabase6); // ticket #2221
|
||||
TEST_CASE(symboldatabase7); // ticket #2230
|
||||
TEST_CASE(symboldatabase8); // ticket #2252
|
||||
TEST_CASE(symboldatabase9); // ticket #2525
|
||||
}
|
||||
|
||||
// Check the operator Equal
|
||||
|
@ -5408,6 +5409,21 @@ private:
|
|||
ASSERT_EQUALS("", errout.str());
|
||||
}
|
||||
|
||||
void symboldatabase9()
|
||||
{
|
||||
// ticket #2425 - segmentation fault
|
||||
checkConst("class CHyperlink : public CString\n"
|
||||
"{\n"
|
||||
"public:\n"
|
||||
" const CHyperlink& operator=(LPCTSTR lpsz) {\n"
|
||||
" CString::operator=(lpsz);\n"
|
||||
" return *this;\n"
|
||||
" }\n"
|
||||
"};\n");
|
||||
|
||||
ASSERT_EQUALS("", errout.str());
|
||||
}
|
||||
|
||||
};
|
||||
|
||||
REGISTER_TEST(TestClass)
|
||||
|
|
Loading…
Reference in New Issue