[Bug]: Segmentation fault with EXPECT_* failure when using std::vector #4450
Unanswered
josearnal
asked this question in
Community Help
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Describe the issue
When looping through the elements of a vector and testing each value, if the vector is too long and the test fails, a segmentation fault will occur.
Here are two basic tests to reproduce the problem. The first one will fail but not seg fault. Thew later will seg fault.
I've also encountered similar problems if the name of the vector is long, but I am having troubles making a minimal reproducible example for this case.
EDIT:
It turns out that merely initializing "long" vectors causes segmentation faults. What's going on here? For example, the following test will seg fault.
Steps to reproduce the problem
Here's my
CMakeLists.txt
What version of GoogleTest are you using?
1.14
What operating system and version are you using?
Linux: AlmaLinux 8.5 (Arctic Sphynx)
What compiler and version are you using?
gcc version 8.5.0 20210514 (Red Hat 8.5.0-4) (GCC)
What build system are you using?
cmake version 3.20.2
Additional context
No response
Beta Was this translation helpful? Give feedback.
All reactions