diff options
author | George Kiagiadakis <george.kiagiadakis@collabora.com> | 2021-06-15 17:43:22 +0300 |
---|---|---|
committer | George Kiagiadakis <george.kiagiadakis@collabora.com> | 2021-07-28 13:19:02 +0300 |
commit | cc3391e17616173eecb5fd7cba2e966ffcc3959b (patch) | |
tree | e2ac6b9df6f501d88e1a74a2c6fe09b23fd01fce /lib | |
parent | e599f7108514fb1f93908a108711268ea79cc6fd (diff) |
lib: fix some issues found by coverity
Signed-off-by: George Kiagiadakis <george.kiagiadakis@collabora.com>
Diffstat (limited to 'lib')
-rw-r--r-- | lib/server.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/lib/server.c b/lib/server.c index a798894..86f8322 100644 --- a/lib/server.c +++ b/lib/server.c @@ -121,8 +121,11 @@ icipc_server_new (const char *path, bool start) pthread_mutex_init (&priv->mutex, NULL); priv->n_request_handlers = 0; - if (start) - icipc_receiver_start (base); + if (start && !icipc_receiver_start (base)) { + icipc_log_error ("failed to start receiver"); + icipc_server_free ((struct icipc_server *)base); + return NULL; + } return (struct icipc_server *)base; } |