** Description changed:

  Initially reported at
  https://gcc.gnu.org/bugzilla/show_bug.cgi?id=118538
+ 
+ The attached reproduction throws a segfault rather than a `terminate
+ called after throwing an instance of 'int'` message.
+ 
+ g++-14 -O0 -std=c++17 -Wall -Wextra -Wpedantic -Wuninitialized 
-fno-strict-aliasing -fwrapv -g3 test.cpp && ./a.out
+ test.cpp: In function ‘int main()’:
+ test.cpp:55:10: warning: variable ‘reader’ set but not used 
[-Wunused-but-set-variable]
+    55 |     auto reader = Reader("file", 1);
+       |          ^~~~~~
+ [1]    473461 segmentation fault (core dumped)  ./a.out
  
  Seems to happen on ubuntu 24.04 arm64 running on a raspberry pi 5
  
  Operating System: Ubuntu 24.04.1 LTS
-           Kernel: Linux 6.8.0-1017-raspi
-     Architecture: arm64
- 
- The attached reproduction throws a segfault rather than throwing the
- raised exception properly.
- 
- g++-14 -O0 -std=c++17 -Wall -Wextra -Wpedantic -Wuninitialized 
-fno-strict-aliasing -fwrapv -g3 test.cpp && ./a.out
- test.cpp: In function ‘int main()’:
- test.cpp:55:10: warning: variable ‘reader’ set but not used 
[-Wunused-but-set-variable]
-    55 |     auto reader = Reader("file", 1);
-       |          ^~~~~~
- [1]    473461 segmentation fault (core dumped)  ./a.out
+           Kernel: Linux 6.8.0-1017-raspi
+     Architecture: arm64

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/2095206

Title:
  throw not caught causing an seg fault rather than a `terminate called
  after throwing an instance of 'int'` message

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/gcc-14/+bug/2095206/+subscriptions


-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to