diff options
Diffstat (limited to 'source4/libcli/smb2/setinfo.c')
-rw-r--r-- | source4/libcli/smb2/setinfo.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/source4/libcli/smb2/setinfo.c b/source4/libcli/smb2/setinfo.c index d6c5555a33..ce03a69482 100644 --- a/source4/libcli/smb2/setinfo.c +++ b/source4/libcli/smb2/setinfo.c @@ -30,13 +30,20 @@ */ struct smb2_request *smb2_setinfo_send(struct smb2_tree *tree, struct smb2_setinfo *io) { + NTSTATUS status; struct smb2_request *req; req = smb2_request_init_tree(tree, SMB2_OP_SETINFO, 0x20, io->in.blob.length); if (req == NULL) return NULL; SSVAL(req->out.body, 0x02, io->in.level); - smb2_push_s32o32_blob(&req->out, 0x04, io->in.blob); + + status = smb2_push_s32o32_blob(&req->out, 0x04, io->in.blob); + if (!NT_STATUS_IS_OK(status)) { + talloc_free(req); + return NULL; + } + SIVAL(req->out.body, 0x0C, io->in.flags); smb2_push_handle(req->out.body+0x10, &io->in.handle); |