Browse Source

moving startup code before register_sync_callbacks()

sync
Volker Birk 7 years ago
parent
commit
05c66d5a74
  1. 6
      Adapter.hxx

6
Adapter.hxx

@ -17,13 +17,13 @@ namespace pEp {
template< class T > void sync_thread(T *obj, function< void(T *) > _startup, function< void(T *) > _shutdown)
{
if (obj && _startup)
_startup(obj);
PEP_STATUS status = register_sync_callbacks(session(), nullptr,
_notifyHandshake, _retrieve_next_sync_event);
throw_status(status);
if (obj && _startup)
_startup(obj);
do_sync_protocol(session(), (void *)obj);
unregister_sync_callbacks(session());

Loading…
Cancel
Save