Skip to content

Commit 55f34fc

Browse files
authored
Merge pull request #200 from Freax13/feature/proc-fd-link-path
resolve path fds relative to their actual location
2 parents 37be5e8 + 227fcb1 commit 55f34fc

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

tee/kernel/src/fs/node/procfs.rs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2088,6 +2088,11 @@ impl INode for FdINode {
20882088
ctx: &mut FileAccessContext,
20892089
) -> Result<Option<Link>> {
20902090
ctx.follow_symlink()?;
2091+
let location = if let Some(link) = self.fd.path_fd_link() {
2092+
link.location.clone()
2093+
} else {
2094+
location
2095+
};
20912096
Ok(Some(Link {
20922097
location,
20932098
node: Arc::new(FollowedFdINode {

0 commit comments

Comments
 (0)