ui: add safety check to prevent ui overlay access to invalid data (#35432)

check ui_state.started
pull/35426/head
Dean Lee 1 week ago committed by GitHub
parent 1a84b05bde
commit 28bf362f69
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
  1. 4
      selfdrive/ui/onroad/augmented_road_view.py

@ -44,6 +44,10 @@ class AugmentedRoadView(CameraView):
self.driver_state_renderer = DriverStateRenderer()
def render(self, rect):
# Only render when system is started to avoid invalid data access
if not ui_state.started:
return
# Update calibration before rendering
self._update_calibration()

Loading…
Cancel
Save