1
0
mirror of https://gitlab.xiph.org/xiph/icecast-server.git synced 2024-09-22 04:15:54 -04:00

Feature: Log HTTP method used to start a source

This commit is contained in:
Philipp Schafft 2019-05-14 07:47:23 +00:00
parent 7aaf0c0e86
commit 0467ef5657

View File

@ -880,8 +880,12 @@ static inline void source_startup(client_t *client)
/* only called for native icecast source clients */ /* only called for native icecast source clients */
static void _handle_source_request(client_t *client) static void _handle_source_request(client_t *client)
{ {
ICECAST_LOG_INFO("Source logging in at mountpoint \"%s\" from %s as role %s", const char *method = httpp_getvar(client->parser, HTTPP_VAR_REQ_TYPE);
client->uri, client->con->ip, client->role);
ICECAST_LOG_INFO("Source logging in at mountpoint \"%s\" using %s%H%s from %s as role %s",
client->uri,
((method) ? "\"" : "<"), ((method) ? method : "unknown"), ((method) ? "\"" : "<"),
client->con->ip, client->role);
if (client->uri[0] != '/') { if (client->uri[0] != '/') {
ICECAST_LOG_WARN("source mountpoint not starting with /"); ICECAST_LOG_WARN("source mountpoint not starting with /");