summaryrefslogtreecommitdiff
path: root/source4/librpc
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2009-02-05 11:18:12 +0100
committerStefan Metzmacher <metze@samba.org>2009-02-05 17:48:13 +0100
commitba0042fcdb028688768184d0831a9f6afb8f7269 (patch)
tree4aa19c2d6d23be38a7419a19193f53bd9d58f1e7 /source4/librpc
parent0872fa7b1f60aeb4e6d5bb1eb40fcba35fdf85d4 (diff)
downloadsamba-ba0042fcdb028688768184d0831a9f6afb8f7269.tar.gz
samba-ba0042fcdb028688768184d0831a9f6afb8f7269.tar.bz2
samba-ba0042fcdb028688768184d0831a9f6afb8f7269.zip
s4:pyrpc: fix compiler warnings
metze
Diffstat (limited to 'source4/librpc')
-rw-r--r--source4/librpc/rpc/pyrpc.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/source4/librpc/rpc/pyrpc.c b/source4/librpc/rpc/pyrpc.c
index 371e111c67..252883c851 100644
--- a/source4/librpc/rpc/pyrpc.c
+++ b/source4/librpc/rpc/pyrpc.c
@@ -29,7 +29,9 @@
#define Py_RETURN_NONE return Py_INCREF(Py_None), Py_None
#endif
-static PyObject *py_dcerpc_run_function(dcerpc_InterfaceObject *iface, struct PyNdrRpcMethodDef *md, PyObject *args, PyObject *kwargs)
+static PyObject *py_dcerpc_run_function(dcerpc_InterfaceObject *iface,
+ const struct PyNdrRpcMethodDef *md,
+ PyObject *args, PyObject *kwargs)
{
TALLOC_CTX *mem_ctx;
NTSTATUS status;
@@ -74,7 +76,7 @@ static PyObject *py_dcerpc_run_function(dcerpc_InterfaceObject *iface, struct Py
static PyObject *py_dcerpc_call_wrapper(PyObject *self, PyObject *args, void *wrapped, PyObject *kwargs)
{
dcerpc_InterfaceObject *iface = (dcerpc_InterfaceObject *)self;
- struct PyNdrRpcMethodDef *md = wrapped;
+ const struct PyNdrRpcMethodDef *md = (const struct PyNdrRpcMethodDef *)wrapped;
return py_dcerpc_run_function(iface, md, args, kwargs);
}
@@ -85,7 +87,7 @@ bool PyInterface_AddNdrRpcMethods(PyTypeObject *ifacetype, const struct PyNdrRpc
int i;
for (i = 0; mds[i].name; i++) {
PyObject *ret;
- struct wrapperbase *wb = calloc(sizeof(struct wrapperbase), 1);
+ struct wrapperbase *wb = (struct wrapperbase *)calloc(sizeof(struct wrapperbase), 1);
wb->name = discard_const_p(char, mds[i].name);
wb->flags = PyWrapperFlag_KEYWORDS;