Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Xiph.Org
Icecast-Server
Commits
7b84c45a
Commit
7b84c45a
authored
Sep 20, 2018
by
Philipp Schafft
🦁
Browse files
Fix: Corrected two possible dead-locks.
parent
1e171a8e
Changes
2
Hide whitespace changes
Inline
Side-by-side
src/connection.c
View file @
7b84c45a
...
...
@@ -1341,6 +1341,7 @@ static void _handle_authed_client(client_t *client, void *userdata, auth_result
static
void
_handle_authentication_global
(
client_t
*
client
,
void
*
userdata
,
auth_result
result
)
{
ice_config_t
*
config
;
auth_stack_t
*
authstack
;
auth_stack_release
(
client
->
authstack
);
client
->
authstack
=
NULL
;
...
...
@@ -1353,8 +1354,11 @@ static void _handle_authentication_global(client_t *client, void *userdata, auth
ICECAST_LOG_DEBUG
(
"Trying global authenticators for client %p."
,
client
);
config
=
config_get_config
();
auth_stack_add_client
(
config
->
authstack
,
client
,
_handle_authed_client
,
userdata
);
authstack
=
config
->
authstack
;
auth_stack_addref
(
authstack
);
config_release_config
();
auth_stack_add_client
(
authstack
,
client
,
_handle_authed_client
,
userdata
);
auth_stack_release
(
authstack
);
}
static
inline
mount_proxy
*
__find_non_admin_mount
(
ice_config_t
*
config
,
const
char
*
name
,
mount_type
type
)
...
...
src/stats.c
View file @
7b84c45a
...
...
@@ -843,6 +843,10 @@ static xmlNodePtr _dump_stats_to_doc (xmlNodePtr root, const char *show_mount, i
xmlNodePtr
ret
=
NULL
;
ice_config_t
*
config
;
config
=
config_get_config
();
__add_authstack
(
config
->
authstack
,
root
);
config_release_config
();
thread_mutex_lock
(
&
_stats_mutex
);
/* general stats first */
avlnode
=
avl_get_first
(
_stats
.
global_tree
);
...
...
@@ -855,9 +859,6 @@ static xmlNodePtr _dump_stats_to_doc (xmlNodePtr root, const char *show_mount, i
}
/* now per mount stats */
avlnode
=
avl_get_first
(
_stats
.
source_tree
);
config
=
config_get_config
();
__add_authstack
(
config
->
authstack
,
root
);
config_release_config
();
while
(
avlnode
)
{
stats_source_t
*
source
=
(
stats_source_t
*
)
avlnode
->
key
;
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment