The Samba-Bugzilla – Attachment 16563 Details for
Bug 14671
s3:modules:vfs_virusfilter:vfs_virusfilter_openat breaks with recent VFS changes
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
git-am fix for 4.14.next.
0001-s3-modules-vfs_virusfilter-Recent-New_VFS-changes-br.patch (text/plain), 1.94 KB, created by
Jeremy Allison
on 2021-03-22 21:06:00 UTC
(
hide
)
Description:
git-am fix for 4.14.next.
Filename:
MIME Type:
Creator:
Jeremy Allison
Created:
2021-03-22 21:06:00 UTC
Size:
1.94 KB
patch
obsolete
>From 2fd3e4184a6e1c4b317e4dfec2e0af65452cd3a9 Mon Sep 17 00:00:00 2001 >From: "Trever L. Adams" <trever.adams@gmail.com> >Date: Sat, 13 Mar 2021 12:47:21 -0700 >Subject: [PATCH] s3:modules:vfs_virusfilter: Recent New_VFS changes break > vfs_virusfilter_openat. > >The_New_VFS introduces several changes that broke vfs_virusfilter_openat. The assert to make sure certain checks would work broke. > >This patch fixes those breaks and converts to the SMB_VFS_FSTAT_NEXT instead of SMB_VFS_STAT_NEXT. > >BUG: https://bugzilla.samba.org/show_bug.cgi?id=14671 >RN: vfs_virusfilter_openat support New_VFS FSTAT, avoid SMB_ASSERT(fsp_get_pathref_fd(dirfsp) == AT_FDCWD); problem. > >Signed-off-by: Trever L. Adams" <trever.adams@gmail.com> >Reviewed-by: Jeremy Allison <jra@samba.org> >Reviewed-by: Noel Power <npower@samba.org> > >Autobuild-User(master): Noel Power <npower@samba.org> >Autobuild-Date(master): Mon Mar 22 19:44:30 UTC 2021 on sn-devel-184 > >(cherry picked from commit d6a16ad00e426a6f815215af71c071dd8e85a50a) >--- > source3/modules/vfs_virusfilter.c | 8 ++------ > 1 file changed, 2 insertions(+), 6 deletions(-) > >diff --git a/source3/modules/vfs_virusfilter.c b/source3/modules/vfs_virusfilter.c >index c9f5e2bf908..524e7dfbad9 100644 >--- a/source3/modules/vfs_virusfilter.c >+++ b/source3/modules/vfs_virusfilter.c >@@ -1238,11 +1238,7 @@ static int virusfilter_vfs_openat(struct vfs_handle_struct *handle, > bool ok1; > char *sret = NULL; > struct smb_filename *smb_fname = NULL; >- >- /* >- * For now assert this, so SMB_VFS_NEXT_STAT() below works. >- */ >- SMB_ASSERT(fsp_get_pathref_fd(dirfsp) == AT_FDCWD); >+ SMB_STRUCT_STAT sbuf = smb_fname_in->st; > > SMB_VFS_HANDLE_GET_DATA(handle, config, > struct virusfilter_config, return -1); >@@ -1284,7 +1280,7 @@ static int virusfilter_vfs_openat(struct vfs_handle_struct *handle, > goto virusfilter_vfs_open_next; > } > >- ret = SMB_VFS_NEXT_STAT(handle, smb_fname); >+ ret = SMB_VFS_NEXT_FSTAT(handle, fsp, &sbuf); > if (ret != 0) { > > /* >-- >2.27.0 >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Flags:
npower
:
review+
Actions:
View
Attachments on
bug 14671
:
16541
| 16563