Skip to content

[Backport 2.35-maintenance] Fix incorrectly reported bytes freed for local-overlay-store - #16630

Merged
internal-nix-ci[bot] merged 1 commit into
2.35-maintenancefrom
backport-16616-to-2.35-maintenance
Oct 17, 2026
Merged

internal-nix-ci[bot] merged 1 commit into
2.35-maintenancefrom
backport-16616-to-2.35-maintenance

Conversation

@internal-nix-ci

Copy link
Copy Markdown

Automatic backport to 2.35-maintenance, triggered by a label in #16616.

Today the bytesFreed variable is uninitialized. If no bytes are freed, the number of bytes reported is incorrect. The full behavior of this issue is documented in issue #16269, that I was able to independently reproduce.

To address this, we assign bytesFreed = 0 at initialization, which is consistent with the implementation at the other call sites of deleteStorePath such as  https://github.com/NixOS/nix/blob/a9f38ea0ee89f550616f342386f45e896f4abd18/src/libstore/local-overlay-store.cc#L253.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
(cherry picked from commit 094819a)
@internal-nix-ci
internal-nix-ci Bot enabled auto-merge October 17, 2026 22:59
@github-actions github-actions Bot added the store Issues and pull requests concerning the Nix store label Oct 17, 2026
@internal-nix-ci
internal-nix-ci Bot merged commit 43d8c6c into 2.35-maintenance Oct 17, 2026
16 checks passed
@internal-nix-ci
internal-nix-ci Bot deleted the backport-16616-to-2.35-maintenance branch October 17, 2026 23:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

store Issues and pull requests concerning the Nix store

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant