smbd: move S_ISDIR check up a bit in openat_pathref_fsp()
commit847465b3900ca78046ceaf08d89fdd4535e7193a
authorRalph Boehme <slow@samba.org>
Mon, 11 Jan 2021 08:57:26 +0000 (11 09:57 +0100)
committerRalph Boehme <slow@samba.org>
Mon, 11 Jan 2021 20:25:32 +0000 (11 20:25 +0000)
tree34c4395cf11ee5df4c6f64da89ccdb7e023e8b72
parent08da3439eddf26bdeece1a4e3c729e4dfcbd5d5e
smbd: move S_ISDIR check up a bit in openat_pathref_fsp()

This relies on the caller having stat()ed smb_fname instead of relying on
fd_openat() fstat()ing fsp->fsp_name. Otherwise no change in behaviour.

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Anoop C S <anoopcs@samba.org>
source3/smbd/files.c