mirror of
https://github.com/samba-team/samba.git
synced 2024-12-25 23:21:54 +03:00
r25779: the return value of ndr_pull_set_switch_value() should be checked
metze
(This used to be commit 30a829a359
)
This commit is contained in:
parent
d933f396e8
commit
ad9efe8edd
@ -760,7 +760,7 @@ _PUBLIC_ NTSTATUS ndr_pull_union_blob(const DATA_BLOB *blob, TALLOC_CTX *mem_ctx
|
||||
struct ndr_pull *ndr;
|
||||
ndr = ndr_pull_init_blob(blob, mem_ctx);
|
||||
NT_STATUS_HAVE_NO_MEMORY(ndr);
|
||||
ndr_pull_set_switch_value(ndr, p, level);
|
||||
NDR_CHECK(ndr_pull_set_switch_value(ndr, p, level));
|
||||
NDR_CHECK(fn(ndr, NDR_SCALARS|NDR_BUFFERS, p));
|
||||
return NT_STATUS_OK;
|
||||
}
|
||||
@ -775,7 +775,7 @@ _PUBLIC_ NTSTATUS ndr_pull_union_blob_all(const DATA_BLOB *blob, TALLOC_CTX *mem
|
||||
struct ndr_pull *ndr;
|
||||
ndr = ndr_pull_init_blob(blob, mem_ctx);
|
||||
NT_STATUS_HAVE_NO_MEMORY(ndr);
|
||||
ndr_pull_set_switch_value(ndr, p, level);
|
||||
NDR_CHECK(ndr_pull_set_switch_value(ndr, p, level));
|
||||
NDR_CHECK(fn(ndr, NDR_SCALARS|NDR_BUFFERS, p));
|
||||
if (ndr->offset < ndr->data_size) {
|
||||
return ndr_pull_error(ndr, NDR_ERR_UNREAD_BYTES,
|
||||
|
Loading…
Reference in New Issue
Block a user