mirror of
https://github.com/samba-team/samba.git
synced 2024-12-22 13:34:15 +03:00
preg: Unpack winreg_Data for parsing
It seems that there might be pre-existing endianness issues which would be fixed by the ndr_push. Signed-off-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
This commit is contained in:
parent
572fd6319f
commit
463dcc9094
@ -27,7 +27,7 @@ import "misc.idl";
|
||||
[charset(DOS),value(";"),noprint] uint8 _sep3[2];
|
||||
uint32 size;
|
||||
[charset(DOS),value(";"),noprint] uint8 _sep4[2];
|
||||
uint8 data[size];
|
||||
[subcontext(0),subcontext_size(size),flag(NDR_REMAINING), switch_is(type)] winreg_Data data;
|
||||
[charset(DOS),value("]"),noprint] uint8 _closing_bracket[2];
|
||||
} preg_entry;
|
||||
|
||||
|
@ -119,7 +119,9 @@ static bool gp_reg_entry_from_file_entry(TALLOC_CTX *mem_ctx,
|
||||
return false;
|
||||
|
||||
data->type = r->type;
|
||||
data->data = data_blob_talloc(data, r->data, r->size);
|
||||
|
||||
ndr_push_union_blob(&data->data, mem_ctx, &r->data, r->type,
|
||||
(ndr_push_flags_fn_t)ndr_push_winreg_Data);
|
||||
|
||||
entry = talloc_zero(mem_ctx, struct gp_registry_entry);
|
||||
if (!entry)
|
||||
|
Loading…
Reference in New Issue
Block a user