/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
- * Version 1.3.35
+ * Version 1.3.36
*
* This file is not intended to be easily readable and contains a number of
* coding conventions designed to improve portability and efficiency. Do not make
# endif
#endif
+#ifndef SWIG_MSC_UNSUPPRESS_4505
+# if defined(_MSC_VER)
+# pragma warning(disable : 4505) /* unreferenced local function has been removed */
+# endif
+#endif
+
#ifndef SWIGUNUSEDPARM
# ifdef __cplusplus
# define SWIGUNUSEDPARM(p)
#define SWIG_name "_registry"
-#define SWIGVERSION 0x010335
+#define SWIGVERSION 0x010336
#define SWIG_VERSION SWIGVERSION
typedef struct hive_key hive_key;
+#include "libcli/util/pyerrors.h"
+
+
#include <limits.h>
#if !defined(SWIG_NO_LLONG_MAX)
# if !defined(LLONG_MAX) && defined(__GNUC__) && defined (__LONG_LONG_MAX__)
SWIGINTERN PyObject *_wrap_reg_get_predef_name(PyObject *SWIGUNUSEDPARM(self), PyObject *args, PyObject *kwargs) {
PyObject *resultobj = 0;
uint32_t arg1 ;
- char *result = 0 ;
unsigned int val1 ;
int ecode1 = 0 ;
PyObject * obj0 = 0 ;
char * kwnames[] = {
(char *) "hkey", NULL
};
+ char *result = 0 ;
if (!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O:reg_get_predef_name",kwnames,&obj0)) SWIG_fail;
ecode1 = SWIG_AsVal_unsigned_SS_int(obj0, &val1);
SWIGINTERN PyObject *_wrap_str_regtype(PyObject *SWIGUNUSEDPARM(self), PyObject *args, PyObject *kwargs) {
PyObject *resultobj = 0;
int arg1 ;
- char *result = 0 ;
int val1 ;
int ecode1 = 0 ;
PyObject * obj0 = 0 ;
char * kwnames[] = {
(char *) "type", NULL
};
+ char *result = 0 ;
if (!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"O:str_regtype",kwnames,&obj0)) SWIG_fail;
ecode1 = SWIG_AsVal_int(obj0, &val1);
PyObject *resultobj = 0;
TALLOC_CTX *arg1 = (TALLOC_CTX *) 0 ;
struct registry_context **arg2 = (struct registry_context **) 0 ;
- WERROR result;
struct registry_context *tmp2 ;
+ WERROR result;
arg1 = NULL;
arg2 = &tmp2;
if (!SWIG_Python_UnpackTuple(args,"Registry",0,0,0)) SWIG_fail;
result = reg_open_local(arg1,arg2);
if (!W_ERROR_IS_OK(result)) {
- PyObject *obj = Py_BuildValue((char *)"(i,s)", W_ERROR_V(result), win_errstr(result));
- PyErr_SetObject(PyExc_RuntimeError, obj);
+ PyErr_SetWERROR(result);
SWIG_fail;
} else if (resultobj == NULL) {
resultobj = Py_None;
reg *arg1 = (reg *) 0 ;
char *arg2 = (char *) 0 ;
struct registry_key **arg3 = (struct registry_key **) 0 ;
- WERROR result;
void *argp1 = 0 ;
int res1 = 0 ;
int res2 ;
char * kwnames[] = {
(char *) "self",(char *) "name",(char *) "key", NULL
};
+ WERROR result;
if (!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"OOO:reg_get_predefined_key_by_name",kwnames,&obj0,&obj1,&obj2)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_registry_context, 0 | 0 );
arg3 = (struct registry_key **)(argp3);
result = reg_get_predefined_key_by_name(arg1,(char const *)arg2,arg3);
if (!W_ERROR_IS_OK(result)) {
- PyObject *obj = Py_BuildValue((char *)"(i,s)", W_ERROR_V(result), win_errstr(result));
- PyErr_SetObject(PyExc_RuntimeError, obj);
+ PyErr_SetWERROR(result);
SWIG_fail;
} else if (resultobj == NULL) {
resultobj = Py_None;
PyObject *resultobj = 0;
reg *arg1 = (reg *) 0 ;
char *arg2 = (char *) 0 ;
- WERROR result;
void *argp1 = 0 ;
int res1 = 0 ;
int res2 ;
char * kwnames[] = {
(char *) "self",(char *) "path", NULL
};
+ WERROR result;
if (!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"OO:reg_key_del_abs",kwnames,&obj0,&obj1)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_registry_context, 0 | 0 );
arg2 = (char *)(buf2);
result = reg_key_del_abs(arg1,(char const *)arg2);
if (!W_ERROR_IS_OK(result)) {
- PyObject *obj = Py_BuildValue((char *)"(i,s)", W_ERROR_V(result), win_errstr(result));
- PyErr_SetObject(PyExc_RuntimeError, obj);
+ PyErr_SetWERROR(result);
SWIG_fail;
} else if (resultobj == NULL) {
resultobj = Py_None;
reg *arg1 = (reg *) 0 ;
uint32_t arg2 ;
struct registry_key **arg3 = (struct registry_key **) 0 ;
- WERROR result;
void *argp1 = 0 ;
int res1 = 0 ;
unsigned int val2 ;
char * kwnames[] = {
(char *) "self",(char *) "hkey_id",(char *) "key", NULL
};
+ WERROR result;
if (!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"OOO:reg_get_predefined_key",kwnames,&obj0,&obj1,&obj2)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_registry_context, 0 | 0 );
arg3 = (struct registry_key **)(argp3);
result = reg_get_predefined_key(arg1,arg2,arg3);
if (!W_ERROR_IS_OK(result)) {
- PyObject *obj = Py_BuildValue((char *)"(i,s)", W_ERROR_V(result), win_errstr(result));
- PyErr_SetObject(PyExc_RuntimeError, obj);
+ PyErr_SetWERROR(result);
SWIG_fail;
} else if (resultobj == NULL) {
resultobj = Py_None;
PyObject *resultobj = 0;
reg *arg1 = (reg *) 0 ;
char *arg2 = (char *) 0 ;
- WERROR result;
void *argp1 = 0 ;
int res1 = 0 ;
int res2 ;
char * kwnames[] = {
(char *) "self",(char *) "filename", NULL
};
+ WERROR result;
if (!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"OO:reg_diff_apply",kwnames,&obj0,&obj1)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_registry_context, 0 | 0 );
arg2 = (char *)(buf2);
result = reg_diff_apply(arg1,(char const *)arg2);
if (!W_ERROR_IS_OK(result)) {
- PyObject *obj = Py_BuildValue((char *)"(i,s)", W_ERROR_V(result), win_errstr(result));
- PyErr_SetObject(PyExc_RuntimeError, obj);
+ PyErr_SetWERROR(result);
SWIG_fail;
} else if (resultobj == NULL) {
resultobj = Py_None;
struct registry_context *arg2 = (struct registry_context *) 0 ;
struct reg_diff_callbacks *arg3 = (struct reg_diff_callbacks *) 0 ;
void *arg4 = (void *) 0 ;
- WERROR result;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
char * kwnames[] = {
(char *) "self",(char *) "ctx2",(char *) "callbacks",(char *) "callback_data", NULL
};
+ WERROR result;
if (!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"OOOO:reg_generate_diff",kwnames,&obj0,&obj1,&obj2,&obj3)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_registry_context, 0 | 0 );
}
result = reg_generate_diff(arg1,arg2,(struct reg_diff_callbacks const *)arg3,arg4);
if (!W_ERROR_IS_OK(result)) {
- PyObject *obj = Py_BuildValue((char *)"(i,s)", W_ERROR_V(result), win_errstr(result));
- PyErr_SetObject(PyExc_RuntimeError, obj);
+ PyErr_SetWERROR(result);
SWIG_fail;
} else if (resultobj == NULL) {
resultobj = Py_None;
struct hive_key *arg2 = (struct hive_key *) 0 ;
uint32_t arg3 ;
char **arg4 = (char **) NULL ;
- WERROR result;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
unsigned int val3 ;
int ecode3 = 0 ;
+ WERROR result;
if ((nobjs < 3) || (nobjs > 4)) SWIG_fail;
res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_registry_context, 0 | 0 );
}
result = reg_mount_hive(arg1,arg2,arg3,(char const **)arg4);
if (!W_ERROR_IS_OK(result)) {
- PyObject *obj = Py_BuildValue((char *)"(i,s)", W_ERROR_V(result), win_errstr(result));
- PyErr_SetObject(PyExc_RuntimeError, obj);
+ PyErr_SetWERROR(result);
SWIG_fail;
} else if (resultobj == NULL) {
resultobj = Py_None;
struct hive_key *arg2 = (struct hive_key *) 0 ;
uint32_t arg3 ;
char **arg4 = (char **) 0 ;
- struct registry_key *result = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
char * kwnames[] = {
(char *) "self",(char *) "hive",(char *) "predef_key",(char *) "elements", NULL
};
+ struct registry_key *result = 0 ;
if (!PyArg_ParseTupleAndKeywords(args,kwargs,(char *)"OOOO:reg_import_hive_key",kwnames,&obj0,&obj1,&obj2,&obj3)) SWIG_fail;
res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_registry_context, 0 | 0 );
reg *arg1 = (reg *) 0 ;
struct hive_key *arg2 = (struct hive_key *) 0 ;
char *arg3 = (char *) 0 ;
- WERROR result;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res3 ;
char *buf3 = 0 ;
int alloc3 = 0 ;
+ WERROR result;
if ((nobjs < 3) || (nobjs > 3)) SWIG_fail;
res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_registry_context, 0 | 0 );
arg3 = (char *)(buf3);
result = reg_mount_hive__SWIG_1(arg1,arg2,(char const *)arg3);
if (!W_ERROR_IS_OK(result)) {
- PyObject *obj = Py_BuildValue((char *)"(i,s)", W_ERROR_V(result), win_errstr(result));
- PyErr_SetObject(PyExc_RuntimeError, obj);
+ PyErr_SetWERROR(result);
SWIG_fail;
} else if (resultobj == NULL) {
resultobj = Py_None;
}
arg1 = (reg *)(argp1);
free((char *) arg1);
-
resultobj = SWIG_Py_Void();
return resultobj;
fail:
struct event_context *arg5 = (struct event_context *) 0 ;
struct loadparm_context *arg6 = (struct loadparm_context *) 0 ;
struct hive_key **arg7 = (struct hive_key **) 0 ;
- WERROR result;
int res2 ;
char *buf2 = 0 ;
int alloc2 = 0 ;
char * kwnames[] = {
(char *) "location",(char *) "session_info",(char *) "credentials",(char *) "ev_ctx",(char *) "lp_ctx", NULL
};
+ WERROR result;
arg3 = NULL;
arg4 = NULL;
}
result = reg_open_hive(arg1,(char const *)arg2,arg3,arg4,arg5,arg6,arg7);
if (!W_ERROR_IS_OK(result)) {
- PyObject *obj = Py_BuildValue((char *)"(i,s)", W_ERROR_V(result), win_errstr(result));
- PyErr_SetObject(PyExc_RuntimeError, obj);
+ PyErr_SetWERROR(result);
SWIG_fail;
} else if (resultobj == NULL) {
resultobj = Py_None;
struct event_context *arg5 = (struct event_context *) 0 ;
struct loadparm_context *arg6 = (struct loadparm_context *) 0 ;
struct hive_key **arg7 = (struct hive_key **) 0 ;
- WERROR result;
int res2 ;
char *buf2 = 0 ;
int alloc2 = 0 ;
char * kwnames[] = {
(char *) "location",(char *) "session_info",(char *) "credentials",(char *) "ev_ctx",(char *) "lp_ctx", NULL
};
+ WERROR result;
arg3 = NULL;
arg4 = NULL;
}
result = reg_open_ldb_file(arg1,(char const *)arg2,arg3,arg4,arg5,arg6,arg7);
if (!W_ERROR_IS_OK(result)) {
- PyObject *obj = Py_BuildValue((char *)"(i,s)", W_ERROR_V(result), win_errstr(result));
- PyErr_SetObject(PyExc_RuntimeError, obj);
+ PyErr_SetWERROR(result);
SWIG_fail;
} else if (resultobj == NULL) {
resultobj = Py_None;
TALLOC_CTX *arg1 = (TALLOC_CTX *) 0 ;
char *arg2 = (char *) 0 ;
struct hive_key **arg3 = (struct hive_key **) 0 ;
- WERROR result;
int res2 ;
char *buf2 = 0 ;
int alloc2 = 0 ;
char * kwnames[] = {
(char *) "location", NULL
};
+ WERROR result;
arg1 = NULL;
arg3 = &tmp3;
arg2 = (char *)(buf2);
result = reg_create_directory(arg1,(char const *)arg2,arg3);
if (!W_ERROR_IS_OK(result)) {
- PyObject *obj = Py_BuildValue((char *)"(i,s)", W_ERROR_V(result), win_errstr(result));
- PyErr_SetObject(PyExc_RuntimeError, obj);
+ PyErr_SetWERROR(result);
SWIG_fail;
} else if (resultobj == NULL) {
resultobj = Py_None;
TALLOC_CTX *arg1 = (TALLOC_CTX *) 0 ;
char *arg2 = (char *) 0 ;
struct hive_key **arg3 = (struct hive_key **) 0 ;
- WERROR result;
int res2 ;
char *buf2 = 0 ;
int alloc2 = 0 ;
char * kwnames[] = {
(char *) "location", NULL
};
+ WERROR result;
arg1 = NULL;
arg3 = &tmp3;
arg2 = (char *)(buf2);
result = reg_open_directory(arg1,(char const *)arg2,arg3);
if (!W_ERROR_IS_OK(result)) {
- PyObject *obj = Py_BuildValue((char *)"(i,s)", W_ERROR_V(result), win_errstr(result));
- PyErr_SetObject(PyExc_RuntimeError, obj);
+ PyErr_SetWERROR(result);
SWIG_fail;
} else if (resultobj == NULL) {
resultobj = Py_None;
struct loadparm_context *arg4 = (struct loadparm_context *) 0 ;
struct auth_session_info *arg5 = (struct auth_session_info *) 0 ;
struct cli_credentials *arg6 = (struct cli_credentials *) 0 ;
- WERROR result;
struct registry_context *tmp2 ;
void *argp3 = 0 ;
int res3 = 0 ;
char * kwnames[] = {
(char *) "ev_ctx",(char *) "lp_ctx",(char *) "session_info",(char *) "credentials", NULL
};
+ WERROR result;
arg3 = event_context_init(NULL);
arg4 = loadparm_init(NULL);
}
result = reg_open_samba(arg1,arg2,arg3,arg4,arg5,arg6);
if (!W_ERROR_IS_OK(result)) {
- PyObject *obj = Py_BuildValue((char *)"(i,s)", W_ERROR_V(result), win_errstr(result));
- PyErr_SetObject(PyExc_RuntimeError, obj);
+ PyErr_SetWERROR(result);
SWIG_fail;
} else if (resultobj == NULL) {
resultobj = Py_None;