aboutsummaryrefslogtreecommitdiff
path: root/brillo/files/safe_fd.h
diff options
context:
space:
mode:
Diffstat (limited to 'brillo/files/safe_fd.h')
-rw-r--r--brillo/files/safe_fd.h7
1 files changed, 5 insertions, 2 deletions
diff --git a/brillo/files/safe_fd.h b/brillo/files/safe_fd.h
index 5e126b4..3c77362 100644
--- a/brillo/files/safe_fd.h
+++ b/brillo/files/safe_fd.h
@@ -183,10 +183,13 @@ class SafeFD {
// recursive - if true also unlink child paths.
// max_depth - limit on recursion depth to prevent fd exhaustion and stack
// overflows.
+ // keep_going - in recursive case continue deleting even in the face of
+ // errors. If all entries cannot be deleted, the last error encountered
+ // during recursion is returned.
BRILLO_EXPORT Error Rmdir(const std::string& name,
bool recursive = false,
- size_t max_depth = kDefaultMaxPathDepth)
- WARN_UNUSED_RESULT;
+ size_t max_depth = kDefaultMaxPathDepth,
+ bool keep_going = true) WARN_UNUSED_RESULT;
private:
BRILLO_EXPORT static const char* RootPath;