}
/*******************************************************************
- Reads or writes a struct uuid
+ Reads or writes a struct GUID
********************************************************************/
-BOOL smb_io_uuid(const char *desc, struct uuid *uuid,
+BOOL smb_io_uuid(const char *desc, struct GUID *uuid,
prs_struct *ps, int depth)
{
if (uuid == NULL)
size_t create_rpc_blob(RPC_DATA_BLOB *str, size_t len)
{
- str->buffer = TALLOC_ZERO(get_talloc_ctx(), len);
+ str->buffer = (uint8 *)TALLOC_ZERO(get_talloc_ctx(), len);
if (str->buffer == NULL)
smb_panic("create_rpc_blob: talloc fail\n");
return len;
if (buf != NULL) {
SMB_ASSERT(str->buf_max_len >= str->buf_len);
- str->buffer = TALLOC_ZERO(get_talloc_ctx(), str->buf_max_len);
+ str->buffer = (uint16 *)TALLOC_ZERO(get_talloc_ctx(),
+ str->buf_max_len);
if (str->buffer == NULL)
smb_panic("init_regval_buffer: talloc fail\n");
memcpy(str->buffer, buf, str->buf_len);
/* store the string */
if(str_len != 0) {
- str->buffer = TALLOC_ZERO(get_talloc_ctx(), str->str_max_len);
+ str->buffer = (uint8 *)TALLOC_ZERO(get_talloc_ctx(),
+ str->str_max_len);
if (str->buffer == NULL)
smb_panic("init_string2: malloc fail\n");
memcpy(str->buffer, buf, str_len);
if(UNMARSHALLING(ps))
ZERO_STRUCTP(pol);
- if (!prs_uint32("data1", ps, depth, &pol->data1))
+ if (!prs_uint32("handle_type", ps, depth, &pol->handle_type))
return False;
- if (!prs_uint32("data2", ps, depth, &pol->data2))
- return False;
- if (!prs_uint16("data3", ps, depth, &pol->data3))
- return False;
- if (!prs_uint16("data4", ps, depth, &pol->data4))
- return False;
- if(!prs_uint8s (False, "data5", ps, depth, pol->data5, sizeof(pol->data5)))
+ if (!smb_io_uuid("uuid", (struct GUID*)&pol->uuid, ps, depth))
return False;
return True;