Fix crash on !p command, getTZ() bounds check, and worldmap JS variable#302
Open
Bwooce wants to merge 1 commit intoG4lile0:betafrom
Open
Fix crash on !p command, getTZ() bounds check, and worldmap JS variable#302Bwooce wants to merge 1 commit intoG4lile0:betafrom
Bwooce wants to merge 1 commit intoG4lile0:betafrom
Conversation
9 tasks
f6c8424 to
ef00b77
Compare
Three independent stability fixes: 1. Guard !p command when radio HAL not initialized - the test packet command dereferences radioHal without checking, crashing on unconfigured boards. 2. Guard getTZ() against short/empty timezone buffer - unconditionally skipping 3 chars for deduplication prefix reads past buffer end on first boot. Returns "GMT0" as safe default. 3. Correct worldmap JS variable reference - AJAX handler used 'x.status' (console script variable) instead of 'wmx.status', preventing worldmap data updates when both scripts are active.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Pre-work for an upcoming update to the LilyGo/TTGO T-Beam Supreme support. These are standalone bug fixes found during that development.
!ptest packet command when radio HAL is not yet initialized (crash atRadio::sendTxwhen board is unconfigured)getTZ()to return"GMT0"when timezone string is shorter than 3 characters, preventing out-of-bounds readx.statusinstead ofwmx.statusChanges
tinyGS.ino: addradio.isReady()check before!phandlerConfigManager.h: addstrlenguard ingetTZ()html.h: fix variable reference in worldmap script3 files changed, 7 insertions(+), 2 deletions(-)
Test plan
Testing
Tested on LilyGo T-Beam Supreme (ESP32-S3 + SX1262) running continuously for 3+ days with no stability issues.
Disclosure
This PR was built with AI assistance (Claude) under full human supervision, with all changes reviewed and tested on hardware by the author.