summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--source3/python/py_spoolss_printers_conv.c17
1 files changed, 14 insertions, 3 deletions
diff --git a/source3/python/py_spoolss_printers_conv.c b/source3/python/py_spoolss_printers_conv.c
index 4b78f087e6..89980ef25a 100644
--- a/source3/python/py_spoolss_printers_conv.c
+++ b/source3/python/py_spoolss_printers_conv.c
@@ -253,7 +253,7 @@ BOOL py_to_PRINTER_INFO_2(PRINTER_INFO_2 *info, PyObject *dict,
BOOL py_from_PRINTER_INFO_3(PyObject **dict, PRINTER_INFO_3 *info)
{
- PyObject *obj;
+ PyObject *obj;
*dict = from_struct(info, py_PRINTER_INFO_3);
@@ -263,7 +263,18 @@ BOOL py_from_PRINTER_INFO_3(PyObject **dict, PRINTER_INFO_3 *info)
return True;
}
-BOOL py_to_PRINTER_INFO_3(PRINTER_INFO_3 *info, PyObject *dict)
+BOOL py_to_PRINTER_INFO_3(PRINTER_INFO_3 *info, PyObject *dict,
+ TALLOC_CTX *mem_ctx)
{
- return False;
+ PyObject *obj;
+
+ to_struct(info, dict, py_PRINTER_INFO_3);
+
+ if (!(obj = PyDict_GetItemString(dict, "security_descriptor")))
+ return False;
+
+ if (!py_to_SECDESC(&info->secdesc, obj, mem_ctx))
+ return False;
+
+ return True;
}