struct RegOpenKey rok;
struct winreg_String key_string, class_string;
enum winreg_CreateAction action = 0;
+ enum winreg_CreateAction *paction = &action;
if ( !hnd )
return CAC_FAILURE;
rpccli_winreg_CreateKey( pipe_hnd, mem_ctx, op->in.parent_key,
key_string, class_string, 0,
op->in.access, NULL, key_out,
- &action );
+ &paction );
if ( !NT_STATUS_IS_OK( hnd->status ) ) {
return CAC_FAILURE;
REGVAL_BUFFER buffer;
REG_VALUE_DATA *data_out = NULL;
enum winreg_Type val_type;
+ enum winreg_Type *pval_type = &val_type;
uint8 *buf;
uint32 buf_size = 4096;
+ uint32 *pbuf_size = &buf_size;
uint32 length = 0;
+ uint32 *plength = &length;
if ( !hnd )
return CAC_FAILURE;
}
hnd->status = rpccli_winreg_QueryValue( pipe_hnd, mem_ctx, op->in.key,
- value_string, &val_type, buf,
- &buf_size, &length );
+ value_string, &pval_type, &buf,
+ &pbuf_size, &plength );
if ( !NT_STATUS_IS_OK( hnd->status ) )
return CAC_FAILURE;
do {
uint32 data_size = maxvalbufsize;
+ uint32 *pdata_size = &data_size;
uint32 data_length = 0;
+ uint32 *pdata_length = &data_length;
struct winreg_StringBuf name_buf;
+ enum winreg_Type *ptype = &types_out[num_values_out];
memset( name_buffer, 0x0, max_valnamelen );
name_buf.name = name_buffer;
hnd->status = rpccli_winreg_EnumValue( pipe_hnd, mem_ctx,
op->in.key,
resume_idx, &name_buf,
- &types_out[num_values_out],
- buffer, &data_size, &data_length );
+ &ptype, &buffer,
+ &pdata_size,
+ &pdata_length );
if ( !NT_STATUS_IS_OK( hnd->status ) )
break;
return r.out.result;
}
-NTSTATUS rpccli_unixinfo_UidToSid(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, uint64_t uid, struct dom_sid *sid)
+NTSTATUS rpccli_unixinfo_UidToSid(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, uint64_t uid, struct dom_sid **sid)
{
struct unixinfo_UidToSid r;
NTSTATUS status;
}
/* Return variables */
- if ( sid ) {
- *sid = *r.out.sid;
- }
+ *sid = r.out.sid;
/* Return result */
return r.out.result;
return r.out.result;
}
-NTSTATUS rpccli_unixinfo_GidToSid(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, uint64_t gid, struct dom_sid *sid)
+NTSTATUS rpccli_unixinfo_GidToSid(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, uint64_t gid, struct dom_sid **sid)
{
struct unixinfo_GidToSid r;
NTSTATUS status;
}
/* Return variables */
- if ( sid ) {
- *sid = *r.out.sid;
- }
+ *sid = r.out.sid;
/* Return result */
return r.out.result;
}
-NTSTATUS rpccli_unixinfo_GetPWUid(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, uint32_t *count, uint64_t *uids, struct unixinfo_GetPWUidInfo *infos)
+NTSTATUS rpccli_unixinfo_GetPWUid(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, uint32_t *count, uint64_t *uids, struct unixinfo_GetPWUidInfo **infos)
{
struct unixinfo_GetPWUid r;
NTSTATUS status;
/* Return variables */
*count = *r.out.count;
- *infos = *r.out.infos;
+ *infos = r.out.infos;
/* Return result */
return r.out.result;
#ifndef __CLI_UNIXINFO__
#define __CLI_UNIXINFO__
NTSTATUS rpccli_unixinfo_SidToUid(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, struct dom_sid sid, uint64_t *uid);
-NTSTATUS rpccli_unixinfo_UidToSid(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, uint64_t uid, struct dom_sid *sid);
+NTSTATUS rpccli_unixinfo_UidToSid(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, uint64_t uid, struct dom_sid **sid);
NTSTATUS rpccli_unixinfo_SidToGid(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, struct dom_sid sid, uint64_t *gid);
-NTSTATUS rpccli_unixinfo_GidToSid(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, uint64_t gid, struct dom_sid *sid);
-NTSTATUS rpccli_unixinfo_GetPWUid(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, uint32_t *count, uint64_t *uids, struct unixinfo_GetPWUidInfo *infos);
+NTSTATUS rpccli_unixinfo_GidToSid(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, uint64_t gid, struct dom_sid **sid);
+NTSTATUS rpccli_unixinfo_GetPWUid(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, uint32_t *count, uint64_t *uids, struct unixinfo_GetPWUidInfo **infos);
#endif /* __CLI_UNIXINFO__ */
return werror_to_ntstatus(r.out.result);
}
-NTSTATUS rpccli_winreg_CreateKey(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, struct policy_handle *handle, struct winreg_String name, struct winreg_String keyclass, uint32_t options, uint32_t access_mask, struct winreg_SecBuf *secdesc, struct policy_handle *new_handle, enum winreg_CreateAction *action_taken)
+NTSTATUS rpccli_winreg_CreateKey(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, struct policy_handle *handle, struct winreg_String name, struct winreg_String keyclass, uint32_t options, uint32_t access_mask, struct winreg_SecBuf *secdesc, struct policy_handle *new_handle, enum winreg_CreateAction **action_taken)
{
struct winreg_CreateKey r;
NTSTATUS status;
r.in.options = options;
r.in.access_mask = access_mask;
r.in.secdesc = secdesc;
- r.in.action_taken = action_taken;
+ r.in.action_taken = *action_taken;
if (DEBUGLEVEL >= 10)
NDR_PRINT_IN_DEBUG(winreg_CreateKey, &r);
/* Return variables */
*new_handle = *r.out.new_handle;
- if ( action_taken ) {
- *action_taken = *r.out.action_taken;
- }
+ *action_taken = r.out.action_taken;
/* Return result */
return werror_to_ntstatus(r.out.result);
return werror_to_ntstatus(r.out.result);
}
-NTSTATUS rpccli_winreg_EnumKey(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, struct policy_handle *handle, uint32_t enum_index, struct winreg_StringBuf *name, struct winreg_StringBuf *keyclass, NTTIME *last_changed_time)
+NTSTATUS rpccli_winreg_EnumKey(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, struct policy_handle *handle, uint32_t enum_index, struct winreg_StringBuf *name, struct winreg_StringBuf **keyclass, NTTIME **last_changed_time)
{
struct winreg_EnumKey r;
NTSTATUS status;
r.in.handle = handle;
r.in.enum_index = enum_index;
r.in.name = name;
- r.in.keyclass = keyclass;
- r.in.last_changed_time = last_changed_time;
+ r.in.keyclass = *keyclass;
+ r.in.last_changed_time = *last_changed_time;
if (DEBUGLEVEL >= 10)
NDR_PRINT_IN_DEBUG(winreg_EnumKey, &r);
/* Return variables */
*name = *r.out.name;
- if ( keyclass ) {
- *keyclass = *r.out.keyclass;
- }
- if ( last_changed_time ) {
- *last_changed_time = *r.out.last_changed_time;
- }
+ *keyclass = r.out.keyclass;
+ *last_changed_time = r.out.last_changed_time;
/* Return result */
return werror_to_ntstatus(r.out.result);
}
-NTSTATUS rpccli_winreg_EnumValue(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, struct policy_handle *handle, uint32_t enum_index, struct winreg_StringBuf *name, enum winreg_Type *type, uint8_t *data, uint32_t *data_size, uint32_t *value_length)
+NTSTATUS rpccli_winreg_EnumValue(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, struct policy_handle *handle, uint32_t enum_index, struct winreg_StringBuf *name, enum winreg_Type **type, uint8_t **data, uint32_t **data_size, uint32_t **value_length)
{
struct winreg_EnumValue r;
NTSTATUS status;
r.in.handle = handle;
r.in.enum_index = enum_index;
r.in.name = name;
- r.in.type = type;
- r.in.data = data;
- r.in.data_size = data_size;
- r.in.value_length = value_length;
+ r.in.type = *type;
+ r.in.data = *data;
+ r.in.data_size = *data_size;
+ r.in.value_length = *value_length;
if (DEBUGLEVEL >= 10)
NDR_PRINT_IN_DEBUG(winreg_EnumValue, &r);
/* Return variables */
*name = *r.out.name;
- if ( type ) {
- *type = *r.out.type;
- }
- if ( data ) {
- *data = *r.out.data;
- }
- if ( data_size ) {
- *data_size = *r.out.data_size;
- }
- if ( value_length ) {
- *value_length = *r.out.value_length;
- }
+ *type = r.out.type;
+ *data = r.out.data;
+ *data_size = r.out.data_size;
+ *value_length = r.out.value_length;
/* Return result */
return werror_to_ntstatus(r.out.result);
return werror_to_ntstatus(r.out.result);
}
-NTSTATUS rpccli_winreg_QueryValue(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, struct policy_handle *handle, struct winreg_String value_name, enum winreg_Type *type, uint8_t *data, uint32_t *data_size, uint32_t *value_length)
+NTSTATUS rpccli_winreg_QueryValue(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, struct policy_handle *handle, struct winreg_String value_name, enum winreg_Type **type, uint8_t **data, uint32_t **data_size, uint32_t **value_length)
{
struct winreg_QueryValue r;
NTSTATUS status;
/* In parameters */
r.in.handle = handle;
r.in.value_name = value_name;
- r.in.type = type;
- r.in.data = data;
- r.in.data_size = data_size;
- r.in.value_length = value_length;
+ r.in.type = *type;
+ r.in.data = *data;
+ r.in.data_size = *data_size;
+ r.in.value_length = *value_length;
if (DEBUGLEVEL >= 10)
NDR_PRINT_IN_DEBUG(winreg_QueryValue, &r);
}
/* Return variables */
- if ( type ) {
- *type = *r.out.type;
- }
- if ( data ) {
- *data = *r.out.data;
- }
- if ( data_size ) {
- *data_size = *r.out.data_size;
- }
- if ( value_length ) {
- *value_length = *r.out.value_length;
- }
+ *type = r.out.type;
+ *data = r.out.data;
+ *data_size = r.out.data_size;
+ *value_length = r.out.value_length;
/* Return result */
return werror_to_ntstatus(r.out.result);
return werror_to_ntstatus(r.out.result);
}
-NTSTATUS rpccli_winreg_QueryMultipleValues(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, struct policy_handle *key_handle, struct QueryMultipleValue *values, uint32_t num_values, uint8_t *buffer, uint32_t *buffer_size)
+NTSTATUS rpccli_winreg_QueryMultipleValues(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, struct policy_handle *key_handle, struct QueryMultipleValue *values, uint32_t num_values, uint8_t **buffer, uint32_t *buffer_size)
{
struct winreg_QueryMultipleValues r;
NTSTATUS status;
r.in.key_handle = key_handle;
r.in.values = values;
r.in.num_values = num_values;
- r.in.buffer = buffer;
+ r.in.buffer = *buffer;
r.in.buffer_size = buffer_size;
if (DEBUGLEVEL >= 10)
/* Return variables */
*values = *r.out.values;
- if ( buffer ) {
- *buffer = *r.out.buffer;
- }
+ *buffer = r.out.buffer;
*buffer_size = *r.out.buffer_size;
/* Return result */
NTSTATUS rpccli_winreg_OpenHKPD(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, uint16_t *system_name, uint32_t access_mask, struct policy_handle *handle);
NTSTATUS rpccli_winreg_OpenHKU(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, uint16_t *system_name, uint32_t access_mask, struct policy_handle *handle);
NTSTATUS rpccli_winreg_CloseKey(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, struct policy_handle *handle);
-NTSTATUS rpccli_winreg_CreateKey(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, struct policy_handle *handle, struct winreg_String name, struct winreg_String keyclass, uint32_t options, uint32_t access_mask, struct winreg_SecBuf *secdesc, struct policy_handle *new_handle, enum winreg_CreateAction *action_taken);
+NTSTATUS rpccli_winreg_CreateKey(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, struct policy_handle *handle, struct winreg_String name, struct winreg_String keyclass, uint32_t options, uint32_t access_mask, struct winreg_SecBuf *secdesc, struct policy_handle *new_handle, enum winreg_CreateAction **action_taken);
NTSTATUS rpccli_winreg_DeleteKey(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, struct policy_handle *handle, struct winreg_String key);
NTSTATUS rpccli_winreg_DeleteValue(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, struct policy_handle *handle, struct winreg_String value);
-NTSTATUS rpccli_winreg_EnumKey(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, struct policy_handle *handle, uint32_t enum_index, struct winreg_StringBuf *name, struct winreg_StringBuf *keyclass, NTTIME *last_changed_time);
-NTSTATUS rpccli_winreg_EnumValue(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, struct policy_handle *handle, uint32_t enum_index, struct winreg_StringBuf *name, enum winreg_Type *type, uint8_t *data, uint32_t *data_size, uint32_t *value_length);
+NTSTATUS rpccli_winreg_EnumKey(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, struct policy_handle *handle, uint32_t enum_index, struct winreg_StringBuf *name, struct winreg_StringBuf **keyclass, NTTIME **last_changed_time);
+NTSTATUS rpccli_winreg_EnumValue(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, struct policy_handle *handle, uint32_t enum_index, struct winreg_StringBuf *name, enum winreg_Type **type, uint8_t **data, uint32_t **data_size, uint32_t **value_length);
NTSTATUS rpccli_winreg_FlushKey(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, struct policy_handle *handle);
NTSTATUS rpccli_winreg_GetKeySecurity(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, struct policy_handle *handle, uint32_t sec_info, struct KeySecurityData *sd);
NTSTATUS rpccli_winreg_LoadKey(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, struct policy_handle *handle, struct winreg_String *keyname, struct winreg_String *filename);
NTSTATUS rpccli_winreg_NotifyChangeKeyValue(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, struct policy_handle *handle, uint8_t watch_subtree, uint32_t notify_filter, uint32_t unknown, struct winreg_String string1, struct winreg_String string2, uint32_t unknown2);
NTSTATUS rpccli_winreg_OpenKey(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, struct policy_handle *parent_handle, struct winreg_String keyname, uint32_t unknown, uint32_t access_mask, struct policy_handle *handle);
NTSTATUS rpccli_winreg_QueryInfoKey(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, struct policy_handle *handle, struct winreg_String *classname, uint32_t *num_subkeys, uint32_t *max_subkeylen, uint32_t *max_classlen, uint32_t *num_values, uint32_t *max_valnamelen, uint32_t *max_valbufsize, uint32_t *secdescsize, NTTIME *last_changed_time);
-NTSTATUS rpccli_winreg_QueryValue(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, struct policy_handle *handle, struct winreg_String value_name, enum winreg_Type *type, uint8_t *data, uint32_t *data_size, uint32_t *value_length);
+NTSTATUS rpccli_winreg_QueryValue(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, struct policy_handle *handle, struct winreg_String value_name, enum winreg_Type **type, uint8_t **data, uint32_t **data_size, uint32_t **value_length);
NTSTATUS rpccli_winreg_ReplaceKey(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx);
NTSTATUS rpccli_winreg_RestoreKey(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, struct policy_handle *handle, struct winreg_String *filename, uint32_t flags);
NTSTATUS rpccli_winreg_SaveKey(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, struct policy_handle *handle, struct winreg_String *filename, struct KeySecurityAttribute *sec_attrib);
NTSTATUS rpccli_winreg_GetVersion(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, struct policy_handle *handle, uint32_t *version);
NTSTATUS rpccli_winreg_OpenHKCC(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, uint16_t *system_name, uint32_t access_mask, struct policy_handle *handle);
NTSTATUS rpccli_winreg_OpenHKDD(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, uint16_t *system_name, uint32_t access_mask, struct policy_handle *handle);
-NTSTATUS rpccli_winreg_QueryMultipleValues(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, struct policy_handle *key_handle, struct QueryMultipleValue *values, uint32_t num_values, uint8_t *buffer, uint32_t *buffer_size);
+NTSTATUS rpccli_winreg_QueryMultipleValues(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, struct policy_handle *key_handle, struct QueryMultipleValue *values, uint32_t num_values, uint8_t **buffer, uint32_t *buffer_size);
NTSTATUS rpccli_winreg_InitiateSystemShutdownEx(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, uint16_t *hostname, struct initshutdown_String *message, uint32_t timeout, uint8_t force_apps, uint8_t reboot, uint32_t reason);
NTSTATUS rpccli_winreg_SaveKeyEx(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx);
NTSTATUS rpccli_winreg_OpenHKPT(struct rpc_pipe_client *cli, TALLOC_CTX *mem_ctx, uint16_t *system_name, uint32_t access_mask, struct policy_handle *handle);
{
if (ndr_flags & NDR_SCALARS) {
NDR_CHECK(ndr_push_align(ndr, 4));
- NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, strlen_m_term(r->name)*2));
+ NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, strlen_m_term_null(r->name)*2));
NDR_CHECK(ndr_push_uint16(ndr, NDR_SCALARS, r->size));
NDR_CHECK(ndr_push_unique_ptr(ndr, r->name));
}
if (r->name) {
NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->size/2));
NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, 0));
- NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, strlen_m_term(r->name)*2/2));
- NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->name, strlen_m_term(r->name)*2/2, sizeof(uint16_t), CH_UTF16));
+ NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, strlen_m_term_null(r->name)*2/2));
+ NDR_CHECK(ndr_push_charset(ndr, NDR_SCALARS, r->name, strlen_m_term_null(r->name)*2/2, sizeof(uint16_t), CH_UTF16));
}
}
return NT_STATUS_OK;
{
ndr_print_struct(ndr, name, "winreg_StringBuf");
ndr->depth++;
- ndr_print_uint16(ndr, "length", (ndr->flags & LIBNDR_PRINT_SET_VALUES)?strlen_m_term(r->name)*2:r->length);
+ ndr_print_uint16(ndr, "length", (ndr->flags & LIBNDR_PRINT_SET_VALUES)?strlen_m_term_null(r->name)*2:r->length);
ndr_print_uint16(ndr, "size", r->size);
ndr_print_ptr(ndr, "name", r->name);
ndr->depth++;
};
struct winreg_StringBuf {
- uint16_t length;/* [value(strlen_m_term(name)*2)] */
+ uint16_t length;/* [value(strlen_m_term_null(name)*2)] */
uint16_t size;
const char *name;/* [unique,length_is(length/2),charset(UTF16),size_is(size/2)] */
};
int argc, const char **argv)
{
uid_t uid;
- DOM_SID sid;
+ DOM_SID *sid;
NTSTATUS result;
if (argc != 2) {
if (!NT_STATUS_IS_OK(result))
goto done;
- printf("%s\n", sid_string_static(&sid));
+ printf("%s\n", sid_string_static(sid));
done:
return result;
int argc, const char **argv)
{
gid_t gid;
- DOM_SID sid;
+ DOM_SID *sid;
NTSTATUS result;
if (argc != 2) {
if (!NT_STATUS_IS_OK(result))
goto done;
- printf("%s\n", sid_string_static(&sid));
+ printf("%s\n", sid_string_static(sid));
done:
return result;
uids[i] = atoi(argv[i+1]);
}
- result = rpccli_unixinfo_GetPWUid(cli, mem_ctx, &num_uids, uids, info);
+ result = rpccli_unixinfo_GetPWUid(cli, mem_ctx, &num_uids, uids,
+ &info);
if (!NT_STATUS_IS_OK(result)) {
return result;
idx = 0;
while ( NT_STATUS_IS_OK(status) ) {
struct winreg_StringBuf class_namebuf;
+ struct winreg_StringBuf *p_class_namebuf = &class_namebuf;
fstring kname;
NTTIME modtime;
+ NTTIME *p_modtime = &modtime;
class_namebuf.name = NULL;
class_namebuf.size = 0;
memset( name_buffer, 0x0, max_subkeylen );
subkey_namebuf.name = name_buffer;
- status = rpccli_winreg_EnumKey(pipe_hnd, mem_ctx, &pol_key, idx,
- &subkey_namebuf, &class_namebuf, &modtime);
+ status = rpccli_winreg_EnumKey(pipe_hnd, mem_ctx, &pol_key,
+ idx, &subkey_namebuf,
+ &p_class_namebuf, &p_modtime);
if ( W_ERROR_EQUAL(ntstatus_to_werror(status), WERR_NO_MORE_ITEMS) ) {
status = NT_STATUS_OK;
status = NT_STATUS_OK;
idx = 0;
while ( NT_STATUS_IS_OK(status) ) {
- enum winreg_Type type;
+ enum winreg_Type type = REG_NONE;
+ enum winreg_Type *ptype = &type;
fstring name;
uint8 *data;
uint32 data_size, value_length;
+ uint32 *pdata_size = &data_size;
+ uint32 *pvalue_length = &value_length;
struct winreg_StringBuf value_namebuf;
REGVAL_BUFFER value;
data_size = max_valbufsize;
value_length = 0;
- status = rpccli_winreg_EnumValue(pipe_hnd, mem_ctx, &pol_key, idx,
- &value_namebuf, &type, data, &data_size, &value_length );
+ status = rpccli_winreg_EnumValue(pipe_hnd, mem_ctx, &pol_key,
+ idx, &value_namebuf, &ptype,
+ &data, &pdata_size,
+ &pvalue_length );
if ( W_ERROR_EQUAL(ntstatus_to_werror(status), WERR_NO_MORE_ITEMS) ) {
status = NT_STATUS_OK;