mirror of
https://github.com/Stremio/stremio-shell-ng.git
synced 2026-05-12 21:40:47 +00:00
start() unconditionally spawned a fresh stremio-runtime every time it was called. Today only the GUI thread calls it, but the crash-restart path can re-fire start() while the previous teardown is still in progress, racing two runtimes for port 11470. Track a `running: Arc<AtomicBool>` on the struct: swap(true) on entry and bail with a log if the previous server thread has not yet flipped it back to false. Reset to false right before sender.notice() so that the GUI's crash handler can legitimately spawn the next instance. Closes #57 |
||
|---|---|---|
| .. | ||
| stremio_app | ||
| main.rs | ||