Skip to content

Add extra guards against segfault#594

Merged
Rainyan merged 1 commit intoNeotokyoRebuild:masterfrom
Rainyan:bug/ghostmarker
Sep 19, 2024
Merged

Add extra guards against segfault#594
Rainyan merged 1 commit intoNeotokyoRebuild:masterfrom
Rainyan:bug/ghostmarker

Conversation

@Rainyan
Copy link
Copy Markdown
Member

@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 label Sep 17, 2024
@nullsystem nullsystem added the Release priority Pull request is a priority for the next 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
@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

Release priority Pull request is a priority for the next release

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants