diff options
Diffstat (limited to 'source4/libcli')
-rw-r--r-- | source4/libcli/smb2/create.c | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/source4/libcli/smb2/create.c b/source4/libcli/smb2/create.c index 1a7f02b070..10fe4f7ce3 100644 --- a/source4/libcli/smb2/create.c +++ b/source4/libcli/smb2/create.c @@ -294,6 +294,21 @@ struct smb2_request *smb2_create_send(struct smb2_tree *tree, struct smb2_create return NULL; } + if (((io->in.fname == NULL) || (strlen(io->in.fname) == 0)) && + (blob.length == 0)) { + struct smb2_request_buffer *buf = &req->out; + + status = smb2_grow_buffer(buf, 1); + if (!NT_STATUS_IS_OK(status)) { + talloc_free(req); + return NULL; + } + buf->dynamic[0] = 0; + buf->dynamic += 1; + buf->body_size += 1; + buf->size += 1; + } + data_blob_free(&blob); smb2_transport_send(req); |