From 1d35fc7f5456c91325745d2914d539cd70763ae4 Mon Sep 17 00:00:00 2001 From: Ralph Boehme Date: Mon, 15 Jun 2020 11:33:39 +0200 Subject: [PATCH] vfs_error_inject: ignore path_ref_fd's This avoids failing opens triggered by filename_convert() -> openat_pathref_fsp(). Signed-off-by: Ralph Boehme Reviewed-by: Jeremy Allison --- source3/modules/vfs_error_inject.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/source3/modules/vfs_error_inject.c b/source3/modules/vfs_error_inject.c index b0fbb652d65..2230b8a2991 100644 --- a/source3/modules/vfs_error_inject.c +++ b/source3/modules/vfs_error_inject.c @@ -115,7 +115,8 @@ static int vfs_error_inject_openat(struct vfs_handle_struct *handle, mode_t mode) { int error = inject_unix_error("openat", handle); - if (error != 0) { + + if (!fsp->fsp_flags.is_pathref && error != 0) { errno = error; return -1; } -- 2.47.3