summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--source3/python/py_spoolss_drivers_conv.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/source3/python/py_spoolss_drivers_conv.c b/source3/python/py_spoolss_drivers_conv.c
index 07823bd3ff..dbf33905ae 100644
--- a/source3/python/py_spoolss_drivers_conv.c
+++ b/source3/python/py_spoolss_drivers_conv.c
@@ -113,9 +113,14 @@ BOOL py_from_DRIVER_INFO_3(PyObject **dict, DRIVER_INFO_3 *info)
BOOL py_to_DRIVER_INFO_3(DRIVER_INFO_3 *info, PyObject *dict)
{
- to_struct(info, dict, py_DRIVER_INFO_3);
+ PyObject *dict_copy = PyDict_Copy(dict);
+ BOOL result;
- return True;
+ PyDict_DelItemString(dict_copy, "level");
+ result = to_struct(info, dict_copy, py_DRIVER_INFO_3);
+
+ Py_DECREF(dict_copy);
+ return result;
}
BOOL py_from_DRIVER_INFO_6(PyObject **dict, DRIVER_INFO_6 *info)