Files
swiftcontrol/lib
Jonas Acker e76dcf9acd fix(android): free network server ports when the app is swiped away
Swiping BikeControl out of recents left the process running: the
keep-alive foreground service was declared stopWithTask="false", and a
process with a foreground service is not killed on task removal. The
activity and its engine were destroyed, but the server sockets of the
dead isolate stayed bound. The next launch got a new engine in the same
process with an empty server registry, so the OpenBikeControl server
walked one port up per relaunch until all five were taken, and the
fixed-port MyWhoosh Link server failed to start at all.

- Stop the foreground service with the task, so swiping the app away
  ends the process like the overlay service already does. Backgrounding
  is unaffected.
- When the engine reports detached, close every network server so the
  ports are released even if the process lives on.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-17 08:06:02 +02:00
..