core: handle client bind errors

When a client attempts to bind to an unexisting global, don't error
but instead let the client know the object was removed.
This commit is contained in:
Wim Taymans 2017-03-09 15:52:19 +01:00
parent 7ad02f553a
commit 1e600713a5
6 changed files with 14 additions and 4 deletions

View file

@ -51,6 +51,7 @@ pinos_resource_new (PinosClient *client,
pinos_signal_init (&this->destroy_signal);
if (!pinos_map_insert_at (&client->objects, this->id, this)) {
pinos_log_debug ("resource %p: id %u in use for client %p", this, id, client);
free (impl);
return NULL;
}