mirror of
https://github.com/NixOS/nix.git
synced 2025-12-03 15:40:59 +01:00
libutil: Make AutoDelete non-copyable and non-movable
This is a good precaution, since we don't want to delete
directories twice accidentally.
(cherry picked from commit 40e3f5c0a4)
This commit is contained in:
parent
3c01ff3148
commit
f67bdae6a6
1 changed files with 4 additions and 0 deletions
|
|
@ -287,6 +287,10 @@ class AutoDelete
|
|||
public:
|
||||
AutoDelete();
|
||||
AutoDelete(const std::filesystem::path & p, bool recursive = true);
|
||||
AutoDelete(AutoDelete &&) = delete;
|
||||
AutoDelete(const AutoDelete &) = delete;
|
||||
AutoDelete & operator=(AutoDelete &&) = delete;
|
||||
AutoDelete & operator=(const AutoDelete &) = delete;
|
||||
~AutoDelete();
|
||||
|
||||
void cancel();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue