Browse Source

treat empty list as None

master
Volker Birk 6 years ago
parent
commit
9201cb10fe
  1. 3
      src/user_interface.cc

3
src/user_interface.cc

@ -54,7 +54,8 @@ namespace pEp {
void UserInterface::deliverHandshakeResult(int result, object identities) void UserInterface::deliverHandshakeResult(int result, object identities)
{ {
identity_list *shared_identities = nullptr; identity_list *shared_identities = nullptr;
if (identities != boost::python::api::object()) { if (identities != boost::python::api::object() &&
boost::python::len(identities)) {
shared_identities = new_identity_list(nullptr); shared_identities = new_identity_list(nullptr);
if (!shared_identities) if (!shared_identities)
throw bad_alloc(); throw bad_alloc();

Loading…
Cancel
Save