Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add extra guards against segfault #594

Merged
merged 1 commit into from
Sep 19, 2024

Conversation

Rainyan
Copy link
Collaborator

@Rainyan Rainyan commented Sep 17, 2024

Description

Add some safety checks before using these pointers, because this area had segfaulted for v8.0-prealpha (Linux):

Trace:

Program terminated with signal SIGSEGV, Segmentation fault.
warning: Section `.reg-xstate/4255' in core file too small.
#0  0xdd621cc3 in CNEOHud_GhostMarker::DrawNeoHudElement (this=0x15ad4800) at /home/runner/work/neo/neo/mp/src/game/client/neo/ui/neo_hud_ghost_marker.cpp:177
[Current thread is 1 (Thread 0xf5be2000 (LWP 4255))]
(gdb) frame 1
#1  0xdd766c0f in vgui::Panel::PaintTraverse (this=0x15ad4848, repaint=<optimized out>, allowForce=true) at /home/runner/work/neo/neo/mp/src/vgui2/vgui_controls/Panel.cpp:1224
(gdb) frame 1
#1  0xdd766c0f in vgui::Panel::PaintTraverse (this=0x15ad4848, repaint=<optimized out>, allowForce=true) at /home/runner/work/neo/neo/mp/src/vgui2/vgui_controls/Panel.cpp:1224
(gdb) frame 0
#0  0xdd621cc3 in CNEOHud_GhostMarker::DrawNeoHudElement (this=0x15ad4800) at /home/runner/work/neo/neo/mp/src/game/client/neo/ui/neo_hud_ghost_marker.cpp:177

The lines referenced: https://github.com/NeotokyoRebuild/neo/blob/v8.0-prealpha/mp/src/game/client/neo/ui/neo_hud_ghost_marker.cpp#L176-L177

Toolchain

  • Linux GCC Distro Native [Mint 21.3 Cinnamon, gcc (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0]

Linked Issues

None

Add some safety checks before using pointers, because this had segfaulted for v8.0-prealpha (Linux)
@Rainyan Rainyan added the bug Something isn't working label Sep 17, 2024
@nullsystem nullsystem added the Minor release priority Pull request is a priority for the next minor release label Sep 18, 2024
@nullsystem nullsystem added this to the v8.1-prealpha milestone Sep 18, 2024
@nullsystem nullsystem requested a review from a team September 18, 2024 20:43
@Rainyan Rainyan merged commit 5b7e8be into NeotokyoRebuild:master Sep 19, 2024
6 checks passed
@Rainyan Rainyan deleted the bug/ghostmarker branch September 19, 2024 10:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working Minor release priority Pull request is a priority for the next minor release
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants