From 3e792be5ed61b96d16bbede259a30b85e6452832 Mon Sep 17 00:00:00 2001 From: Ramon Nou Date: Thu, 15 May 2025 21:12:12 +0200 Subject: [PATCH] bugfix realpath(libc) --- src/client/gkfs_libc.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/client/gkfs_libc.cpp b/src/client/gkfs_libc.cpp index 4584c4deb..a25294234 100644 --- a/src/client/gkfs_libc.cpp +++ b/src/client/gkfs_libc.cpp @@ -1908,7 +1908,10 @@ realpath(const char* path, char* resolved_path) { // provided smaller, this check is tricky. Assuming PATH_MAX // is sufficient. } - strcpy(resolved_path, resolved_str_internal.c_str()); + // we should return the full path (CTX->mountdir() + + // resolved_str_internal) + strcpy(resolved_path, + (CTX->mountdir() + resolved_str_internal).c_str()); return resolved_path; } else if(status == PathStatus::Error) { -- GitLab