summaryrefslogtreecommitdiff
path: root/source3/smbd
diff options
context:
space:
mode:
Diffstat (limited to 'source3/smbd')
-rw-r--r--source3/smbd/nttrans.c8
-rw-r--r--source3/smbd/trans2.c6
2 files changed, 13 insertions, 1 deletions
diff --git a/source3/smbd/nttrans.c b/source3/smbd/nttrans.c
index 28d7a169a8..df65ad7da6 100644
--- a/source3/smbd/nttrans.c
+++ b/source3/smbd/nttrans.c
@@ -1853,8 +1853,14 @@ static int call_nt_transact_rename(connection_struct *conn, char *inbuf, char *o
status = rename_internals(conn, fsp->fsp_name,
new_name, 0, replace_if_exists, path_contains_wcard);
- if (!NT_STATUS_IS_OK(status))
+
+ if (!NT_STATUS_IS_OK(status)) {
+ if (open_was_deferred(SVAL(inbuf,smb_mid))) {
+ /* We have re-scheduled this call. */
+ return -1;
+ }
return ERROR_NT(status);
+ }
/*
* Rename was successful.
diff --git a/source3/smbd/trans2.c b/source3/smbd/trans2.c
index 7bdecd45ca..48a5a0c1ac 100644
--- a/source3/smbd/trans2.c
+++ b/source3/smbd/trans2.c
@@ -4459,9 +4459,15 @@ size = %.0f, uid = %u, gid = %u, raw perms = 0%o\n",
fname, newname ));
status = rename_internals(conn, fname, base_name, 0, overwrite, False);
}
+
if (!NT_STATUS_IS_OK(status)) {
+ if (open_was_deferred(SVAL(inbuf,smb_mid))) {
+ /* We have re-scheduled this call. */
+ return -1;
+ }
return ERROR_NT(status);
}
+
process_pending_change_notify_queue((time_t)0);
SSVAL(params,0,0);
send_trans2_replies(outbuf, bufsize, params, 2, *ppdata, 0, max_data_bytes);