diff options
-rw-r--r-- | usr/src/uts/common/fs/smbsrv/smb_common_open.c | 2 | ||||
-rw-r--r-- | usr/src/uts/common/fs/smbsrv/smb_ofile.c | 2 |
2 files changed, 4 insertions, 0 deletions
diff --git a/usr/src/uts/common/fs/smbsrv/smb_common_open.c b/usr/src/uts/common/fs/smbsrv/smb_common_open.c index 59c892ee88..a4b572ad28 100644 --- a/usr/src/uts/common/fs/smbsrv/smb_common_open.c +++ b/usr/src/uts/common/fs/smbsrv/smb_common_open.c @@ -834,6 +834,8 @@ smb_common_open(smb_request_t *sr) * smb2.durable-open.delete_on_close1 */ DTRACE_PROBE1(node_deleted, smb_node_t, fnode); + tree_fid = of->f_fid; + of->f_fid = 0; smb_ofile_free(of); of = NULL; last_comp_found = B_FALSE; diff --git a/usr/src/uts/common/fs/smbsrv/smb_ofile.c b/usr/src/uts/common/fs/smbsrv/smb_ofile.c index d3f2bad47c..59a3900513 100644 --- a/usr/src/uts/common/fs/smbsrv/smb_ofile.c +++ b/usr/src/uts/common/fs/smbsrv/smb_ofile.c @@ -405,6 +405,8 @@ smb_ofile_open( smb_node_t *node = of->f_node; ASSERT(of->f_state == SMB_OFILE_STATE_ALLOC); + ASSERT(of->f_fid != 0); + of->f_state = SMB_OFILE_STATE_OPEN; switch (of->f_ftype) { |