diff --git a/lib/raop.c b/lib/raop.c index bb7cfa9..d9939ba 100644 --- a/lib/raop.c +++ b/lib/raop.c @@ -386,7 +386,9 @@ conn_request(void *ptr, http_request_t *request, http_response_t **response) { handler = &raop_handler_flush; } else if (!strcmp(method, "TEARDOWN")) { handler = &raop_handler_teardown; - } + } else { + http_response_init(*response, protocol, 501, "Not Implemented"); + } } else if (!hls_request && !strcmp(protocol, "HTTP/1.1")) { if (!strcmp(method, "POST")) { if (!strcmp(url, "/reverse")) { @@ -415,7 +417,6 @@ conn_request(void *ptr, http_request_t *request, http_response_t **response) { } else if (!strcmp(method, "PUT")) { if (!strncmp (url, "/setProperty?", strlen("/setProperty?"))) { handler = &http_handler_set_property; - } else { } } } else if (hls_request) { diff --git a/lib/raop_handlers.h b/lib/raop_handlers.h index 5dc42dc..5f5a5f3 100644 --- a/lib/raop_handlers.h +++ b/lib/raop_handlers.h @@ -537,7 +537,7 @@ raop_handler_options(raop_conn_t *conn, http_request_t *request, http_response_t *response, char **response_data, int *response_datalen) { - http_response_add_header(response, "Public", "SETUP, RECORD, PAUSE, FLUSH, TEARDOWN, OPTIONS, GET_PARAMETER, SET_PARAMETER"); + http_response_add_header(response, "Public", "SETUP, RECORD, FLUSH, TEARDOWN, OPTIONS, GET_PARAMETER, SET_PARAMETER"); } static void