From 9e6e9c7707506709de2b0e765647783f471b412a Mon Sep 17 00:00:00 2001 From: Andreas Schneider Date: Tue, 19 Feb 2013 08:58:00 +0100 Subject: pyauth: Check return value of lpcfg_from_py_object(). Reviewed-by: Alexander Bokovoy --- source4/auth/pyauth.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'source4/auth') diff --git a/source4/auth/pyauth.c b/source4/auth/pyauth.c index f07fa786a1..437e671bba 100644 --- a/source4/auth/pyauth.c +++ b/source4/auth/pyauth.c @@ -245,6 +245,10 @@ static PyObject *py_auth_context_new(PyTypeObject *type, PyObject *args, PyObjec } lp_ctx = lpcfg_from_py_object(mem_ctx, py_lp_ctx); + if (lp_ctx == NULL) { + PyErr_NoMemory(); + return NULL; + } ev = s4_event_context_init(mem_ctx); if (ev == NULL) { -- cgit