Commit 2ffaa92e authored by Philipp Schafft's avatar Philipp Schafft 🦁

Fix: Fixed two double-unlock errors

parent 97181fb1
Pipeline #1795 passed with stage
in 46 seconds
......@@ -8,7 +8,7 @@
* oddsock <oddsock@xiph.org>,
* Karl Heyes <karl@xiph.org>
* and others (see AUTHORS for details).
* Copyright 2011-2018, Philipp "ph3-der-loewe" Schafft <lion@lion.leolix.org>,
* Copyright 2011-2020, Philipp "ph3-der-loewe" Schafft <lion@lion.leolix.org>,
*/
/* client.c
......@@ -988,7 +988,6 @@ ssize_t client_get_baseurl(client_t *client, listensocket_t *listensocket, char
port = listener->port;
if (!client)
tlsmode = listener->tls;
listensocket_release_listener(listensocket);
}
}
......
......@@ -3,7 +3,7 @@
* This program is distributed under the GNU General Public License, version 2.
* A copy of this license is included with this source.
*
* Copyright 2018, Philipp "ph3-der-loewe" Schafft <lion@lion.leolix.org>,
* Copyright 2018-2020, Philipp "ph3-der-loewe" Schafft <lion@lion.leolix.org>,
*/
/**
......@@ -494,8 +494,8 @@ static listensocket_t * listensocket_container_get_by_id(listensocket_container_
listener = listensocket_get_listener(self->sock[i]);
if (listener) {
if (listener->id != NULL && strcmp(listener->id, id) == 0) {
listensocket_release_listener(self->sock[i]);
if (refobject_ref(self->sock[i]) == 0) {
listensocket_release_listener(self->sock[i]);
return self->sock[i];
}
}
......
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