}
static WERROR reg_dir_enum_value(TALLOC_CTX *mem_ctx,
- const struct hive_key *key, int idx,
+ struct hive_key *key, int idx,
const char **name,
uint32_t *type, DATA_BLOB *data)
{
* Retrieve a registry value with a specific index.
*/
WERROR (*enum_value) (TALLOC_CTX *mem_ctx,
- const struct hive_key *key, int idx,
+ struct hive_key *key, int idx,
const char **name, uint32_t *type,
DATA_BLOB *data);
}
/** Get predefined key by id. */
-_PUBLIC_ WERROR reg_get_predefined_key(const struct registry_context *ctx,
+_PUBLIC_ WERROR reg_get_predefined_key(struct registry_context *ctx,
uint32_t hkey, struct registry_key **key)
{
return ctx->ops->get_predefined_key(ctx, hkey, key);
return WERR_OK;
}
-static WERROR ldb_get_value_by_id(TALLOC_CTX *mem_ctx, const struct hive_key *k,
+static WERROR ldb_get_value_by_id(TALLOC_CTX *mem_ctx, struct hive_key *k,
int idx, const char **name,
uint32_t *data_type, DATA_BLOB *data)
{
return WERR_OK;
}
-WERROR local_get_predefined_key(const struct registry_context *ctx,
+WERROR local_get_predefined_key(struct registry_context *ctx,
uint32_t key_id, struct registry_key **key)
{
struct registry_local *rctx = talloc_get_type(ctx,
struct security_descriptor *security,
struct registry_key **key)
{
- const struct local_key *local_parent;
+ struct local_key *local_parent;
struct hive_key *hivekey;
const char **elements;
int i;
last_part = strrchr(name, '\\');
if (last_part == NULL) {
last_part = name;
- local_parent = (const struct local_key *)parent_key;
+ local_parent = (struct local_key *)parent_key;
} else {
W_ERROR_NOT_OK_RETURN(reg_open_key(mem_ctx, parent_key,
talloc_strndup(mem_ctx, name, last_part-name),
- &local_parent));
+ (struct registry_key **)&local_parent));
last_part++;
}
}
-static WERROR regf_get_value(TALLOC_CTX *ctx, const struct hive_key *key,
+static WERROR regf_get_value(TALLOC_CTX *ctx, struct hive_key *key,
int idx, const char **name,
uint32_t *data_type, DATA_BLOB *data)
{
static WERROR regf_del_value (struct hive_key *key, const char *name)
{
- const struct regf_key_data *private_data =
- (const struct regf_key_data *)key;
+ struct regf_key_data *private_data = (struct regf_key_data *)key;
struct regf_data *regf = private_data->hive;
struct nk_block *nk = private_data->nk;
struct vk_block vk;
static WERROR regf_set_value(struct hive_key *key, const char *name,
uint32_t type, const DATA_BLOB data)
{
- const struct regf_key_data *private_data =
- (const struct regf_key_data *)key;
+ struct regf_key_data *private_data = (struct regf_key_data *)key;
struct regf_data *regf = private_data->hive;
struct nk_block *nk = private_data->nk;
struct vk_block vk;
WERROR (*flush_key) (struct registry_key *key);
- WERROR (*get_predefined_key) (const struct registry_context *ctx,
+ WERROR (*get_predefined_key) (struct registry_context *ctx,
uint32_t key_id,
struct registry_key **key);
WERROR reg_get_predefined_key_by_name(struct registry_context *ctx,
const char *name,
struct registry_key **key);
-WERROR reg_get_predefined_key(const struct registry_context *ctx,
+WERROR reg_get_predefined_key(struct registry_context *ctx,
uint32_t hkey,
struct registry_key **key);
static WERROR rpc_query_key(const struct registry_key *k);
-static WERROR rpc_get_predefined_key(const struct registry_context *ctx,
+static WERROR rpc_get_predefined_key(struct registry_context *ctx,
uint32_t hkey_type,
struct registry_key **k)
{
{
struct hive_key *key;
WERROR error;
- const char *dirname;
+ char *dirname;
NTSTATUS status;
status = torture_temp_dir(tctx, "hive-dir", &dirname);
{
struct hive_key *key;
WERROR error;
- const char *dirname;
+ char *dirname;
NTSTATUS status;
status = torture_temp_dir(tctx, "hive-ldb", &dirname);
{
struct hive_key *key;
WERROR error;
- const char *dirname;
+ char *dirname;
NTSTATUS status;
status = torture_temp_dir(tctx, "hive-dir", &dirname);
{
struct registry_context *rctx;
WERROR error;
- const char *tempdir;
+ char *tempdir;
NTSTATUS status;
struct hive_key *hive_key;
const char *filename;