From: Jeremy Allison Date: Mon, 13 Dec 2021 21:44:25 +0000 (-0800) Subject: s3: smbd: In stat_cache_lookup(), use vfs_stat() utility function. X-Git-Tag: tdb-1.4.6~280 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d8f09c1bf097087f287d39b660f135793b652d2d;p=thirdparty%2Fsamba.git s3: smbd: In stat_cache_lookup(), use vfs_stat() utility function. Signed-off-by: Jeremy Allison Reviewed-by: Noel Power --- diff --git a/source3/smbd/statcache.c b/source3/smbd/statcache.c index ddbd663ad5b..f5fa07a8436 100644 --- a/source3/smbd/statcache.c +++ b/source3/smbd/statcache.c @@ -331,12 +331,7 @@ bool stat_cache_lookup(connection_struct *conn, .twrp = twrp, }; - if (posix_paths) { - ret = SMB_VFS_LSTAT(conn, &smb_fname); - } else { - ret = SMB_VFS_STAT(conn, &smb_fname); - } - + ret = vfs_stat(conn, &smb_fname); if (ret != 0) { /* Discard this entry - it doesn't exist in the filesystem. */ memcache_delete(smbd_memcache(), STAT_CACHE,