diff --git a/bindings/python/src/entry.cpp b/bindings/python/src/entry.cpp index b24f6a2cf..861580708 100644 --- a/bindings/python/src/entry.cpp +++ b/bindings/python/src/entry.cpp @@ -49,6 +49,13 @@ struct entry_to_python } } + static PyObject* convert(boost::shared_ptr const& e) + { + if (!e) + return incref(Py_None); + return convert(*e); + } + static PyObject* convert(entry const& e) { return incref(convert0(e).ptr()); @@ -126,6 +133,7 @@ struct entry_from_python void bind_entry() { + to_python_converter, entry_to_python>(); to_python_converter(); entry_from_python(); }