Skip to content

Commit

Permalink
Merge pull request #247 from eminence/statat_nofollow
Browse files Browse the repository at this point in the history
Don't error if the oppportunistic statat fails in fd_count
  • Loading branch information
eminence authored Feb 15, 2023
2 parents 940c163 + d0a7c09 commit 391bd13
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/process/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1183,7 +1183,7 @@ impl Process {
// Use fast path if available (Linux v6.2): https://github.com/torvalds/linux/commit/f1f1f2569901
let stat = wrap_io_error!(
self.root.join("fd"),
rustix::fs::statat(&self.fd, "fd", AtFlags::SYMLINK_NOFOLLOW)
rustix::fs::statat(&self.fd, "fd", AtFlags::empty())
)?;
if stat.st_size > 0 {
return Ok(stat.st_size as usize);
Expand Down

0 comments on commit 391bd13

Please sign in to comment.