Ben Meadors e1ea653a45 fix(graphics): crash and leak fixes across display drivers (#11455)
* fix(graphics): crash and leak fixes across display drivers

- TFTDisplay (portduino): _touch_instance was an uninitialized member,
  and the touch-config block only assigns it for xpt2046/stmpe610/
  ft5x06 while the guard accepts any configured module. A gt911 entry
  in config.yaml (supported by the color-UI path) reached
  _touch_instance->config() through an indeterminate pointer. Initialize
  to nullptr and guard the config block.

- Screen: the destructor freed normalFrames but leaked the owned
  dispdev (driver + framebuffer) and ui objects. Screen is genuinely
  destroyed on the portduino reboot path (screen = nullptr in
  Power.cpp).

- EInkDisplay2: GxEPD2_BW's constructor takes the low-level driver by
  value and stores a copy, so the 'new EINK_DISPLAY_MODEL' at nine
  sites was orphaned the moment connect() returned. Pass temporaries,
  as GxEPD2Multi already does.

- EInkParallelDisplay: the async full-refresh task cleared
  asyncFullRunning before nulling asyncTaskHandle, so the destructor
  could observe running==false with a stale handle and vTaskDelete a
  freed TCB. Null the handle first (same ordering fix the
  eink/Drivers/EInkParallel.cpp sibling already carries).

- Panel_sdl: initFrameBuffer only null-checked the first of its three
  allocations and returned true regardless, leaving the line array
  full of null+offset garbage on failure; later redraws would write
  through those. Check all three, release partial allocations, and
  return false.

* fix(graphics): propagate Panel_sdl framebuffer allocation failure from init()

Per review: initFrameBuffer() can now fail cleanly, so init() must not
register the monitor and report success when it does.
2026-08-18 12:10:03 +00:00
2021-10-09 17:15:12 +11:00
2024-09-24 15:24:08 -05:00
2026-07-01 19:01:27 -05:00
2026-01-29 10:06:58 -06:00
2024-11-28 06:26:51 -06:00
2024-09-04 15:33:28 -07:00
2026-07-28 11:09:40 +00:00
2026-01-29 10:06:58 -06:00
2026-01-29 10:06:58 -06:00
2026-07-01 19:01:27 -05:00
2025-01-13 12:24:05 +08:00
2026-01-29 10:06:58 -06:00

Meshtastic Logo

Meshtastic Firmware

GitHub release downloads CI CLA assistant Fiscal Contributors Vercel

meshtastic%2Ffirmware | Trendshift

Overview

This repository contains the official device firmware for Meshtastic, an open-source LoRa mesh networking project designed for long-range, low-power communication without relying on internet or cellular infrastructure. The firmware supports various hardware platforms, including ESP32, nRF52, RP2040/RP2350, and Linux-based devices.

Meshtastic enables text messaging, location sharing, and telemetry over a decentralized mesh network, making it ideal for outdoor adventures, emergency preparedness, and remote operations.

Get Started

Join our community and help improve Meshtastic! 🚀

Stats

Alt

S
Description
No description provided
Readme GPL-3.0
72 MiB
0 Stars 1 Watchers 0 Forks
2026-09-01 21:05:50 +08:00
Languages
C++ 72.5%
C 23.7%
Python 2%
Shell 1.2%
Batchfile 0.2%
Other 0.2%