Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/windirstat/llfio.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--include/afio/v2.0/detail/impl/posix/fs_handle.ipp4
1 files changed, 4 insertions, 0 deletions
diff --git a/include/afio/v2.0/detail/impl/posix/fs_handle.ipp b/include/afio/v2.0/detail/impl/posix/fs_handle.ipp
index 5848191b..c3c7a95d 100644
--- a/include/afio/v2.0/detail/impl/posix/fs_handle.ipp
+++ b/include/afio/v2.0/detail/impl/posix/fs_handle.ipp
@@ -77,7 +77,11 @@ inline result<path_handle> containing_directory(optional<std::reference_wrapper<
continue;
path_handle currentdirh = std::move(currentdirh_.value());
if(h.flags() & handle::flag::disable_safety_unlinks)
+ {
+ if(out_filename)
+ out_filename->get() = filename.path();
return success(std::move(currentdirh));
+ }
// Open the same file name, and compare dev and inode
path_view::c_str zpath(filename);
int fd = ::openat(currentdirh.native_handle().fd, zpath.buffer, O_CLOEXEC);