zed/crates/auto_update
Lukas Wirth 2eeca73e66
auto_update: Fix installer temp dirs leaking on macOS (#60528)
The unmount of the update disk image was made async-and-detached in
#38867, which introduced a race: the installer TempDir was dropped
(running remove_dir_all) while the DMG was still mounted inside it. The
removal failed silently, leaking a zed-auto-update* dir containing the
~140 MB DMG in /private/var/folders on every update.

Now the unmount is awaited before the temp dir is dropped (installation
already runs on the background executor since #58767, so this no longer
blocks the UI), with the Drop impl kept as a safety net for early exits
and cancellation. Additionally, stale installer dirs older than 24 hours
are swept from the temp dir when update polling starts, so existing
accumulated leaks get reclaimed.

Closes FR-104
Closes #58835

Release Notes:

- Fixed the macOS auto-updater leaking a copy of the downloaded update
in the system temp directory on every update, and added cleanup of
previously leaked files.
2026-07-07 10:23:28 +00:00
..
src auto_update: Fix installer temp dirs leaking on macOS (#60528) 2026-07-07 10:23:28 +00:00
Cargo.toml remote: Add configurable remote server cache retention (default 5) (#47202) 2026-01-26 07:25:51 +00:00
LICENSE-GPL chore: Change AGPL-licensed crates to GPL (except for collab) (#4231) 2024-01-24 00:26:58 +01:00