Skip to content

Clear oceanic clearance cache on flight plan updates to fix track display#602

Closed
MrAdder wants to merge 18 commits intoVATSIM-UK:mainfrom
MrAdder:issue-586
Closed

Clear oceanic clearance cache on flight plan updates to fix track display#602
MrAdder wants to merge 18 commits intoVATSIM-UK:mainfrom
MrAdder:issue-586

Conversation

@MrAdder
Copy link

@MrAdder MrAdder commented Feb 2, 2026

Potentially Fixes #586

Currently unable to test this

Summary of Changes

Your changes fix an issue where assumed aircraft would show incorrect oceanic track information. The modifications improve the oceanic clearance caching mechanism by:

Files Modified:

  1. src/plugin/oceanic/OceanicEventHandler.h - Header file

    • Added include for FlightPlanEventHandlerInterface
    • Made OceanicEventHandler inherit from FlightPlanEventHandlerInterface (in addition to existing base classes)
    • Added three new method declarations for flight plan event handling
  2. src/plugin/oceanic/OceanicEventHandler.cpp - Implementation file

    • Improved code formatting/indentation in the UpdateOceanicClearances() method
    • Implemented FlightPlanEvent() - Clears cached clearance data when a flight plan is updated (including when an aircraft is assumed)
    • Implemented FlightPlanDisconnectEvent() - Removes clearance from cache when a flight plan disconnects
    • Implemented ControllerFlightPlanDataEvent() - Empty handler for controller flight plan data events

Technical Details:

The changes use thread-safe operations (std::lock_guard with clearanceMapMutex) to ensure cache consistency when clearing or removing oceanic clearances during flight plan lifecycle events.

Issue Fixed:

When aircraft are assumed or their flight plans update, the oceanic clearance cache is now properly invalidated, ensuring fresh data is displayed on the next timer trigger rather than showing stale cached information.

@MrAdder MrAdder marked this pull request as draft February 3, 2026 10:00
@MrAdder MrAdder closed this Feb 4, 2026
@MrAdder MrAdder reopened this Feb 4, 2026
@MrAdder MrAdder closed this Feb 4, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Data push from https://nattrak.vatsim.net/ to ES: wrong track indication on assumed label

1 participant