Commit 2112ebba authored by Olivier Crête's avatar Olivier Crête

agent: Remove socket on read error

If a socket returned an error, remove it.
parent 1949b89f
...@@ -5031,6 +5031,10 @@ component_io_cb (GSocket *gsocket, GIOCondition condition, gpointer user_data) ...@@ -5031,6 +5031,10 @@ component_io_cb (GSocket *gsocket, GIOCondition condition, gpointer user_data)
} }
done: done:
if (remove_source)
nice_component_remove_socket (component, socket_source->socket);
/* If we’re in the middle of a read, don’t emit any signals, or we could cause /* If we’re in the middle of a read, don’t emit any signals, or we could cause
* re-entrancy by (e.g.) emitting component-state-changed and having the * re-entrancy by (e.g.) emitting component-state-changed and having the
* client perform a read. */ * client perform a read. */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment