Commits

Aleš Erjavec committed f701448

Prevent the 'attributes' from being deleted.

  • Participants
  • Parent commits 02de8bb

Comments (0)

Files changed (1)

source/orange/lib_kernel.cpp

 
 int Variable_set_attributes(TPyOrange *self, PyObject *dict)
 {
+    if (!dict) {
+        PYERROR(PyExc_TypeError, "Cannot delete 'attributes' dict", 0);
+    }
+
     if (!PyDict_Check(dict)) {
         PYERROR(PyExc_TypeError, "'attributes' must be a dict", 0);
     }