]> git.proxmox.com Git - proxmox-backup.git/commit
datastore: avoid calculating protected attribute twice
authorGabriel Goller <g.goller@proxmox.com>
Wed, 3 Jul 2024 15:02:46 +0000 (17:02 +0200)
committerWolfgang Bumiller <w.bumiller@proxmox.com>
Fri, 12 Jul 2024 11:40:23 +0000 (13:40 +0200)
commit0e9aa78bf4979720eec58352ac7afa6b0b4a8db2
tree2dc1134593fcf1abcc5158c707e9b600e2b9bb7e
parent625e2fd95fee91358a98c37d3f58955d7f1cdc78
datastore: avoid calculating protected attribute twice

The protected status of the snapshot is retrieved twice. This is slow
because it stat's the .protected file multiple times.

Signed-off-by: Gabriel Goller <g.goller@proxmox.com>
Tested-by: Christian Ebner <c.ebner@proxmox.com>
Reviewed-by: Christian Ebner <c.ebner@proxmox.com>
src/api2/admin/datastore.rs