diff --git a/plugins/janus_audiobridge.c b/plugins/janus_audiobridge.c index 767f7f72f0..76ca933fc1 100644 --- a/plugins/janus_audiobridge.c +++ b/plugins/janus_audiobridge.c @@ -1356,6 +1356,7 @@ static struct janus_json_parameter rtp_forward_parameters[] = { static struct janus_json_parameter stop_rtp_forward_parameters[] = { {"stream_id", JSON_INTEGER, JANUS_JSON_PARAM_REQUIRED | JANUS_JSON_PARAM_POSITIVE} }; +#ifdef HAVE_LIBOGG static struct janus_json_parameter play_file_parameters[] = { {"filename", JSON_STRING, JANUS_JSON_PARAM_REQUIRED}, {"file_id", JSON_STRING, 0}, @@ -1365,6 +1366,7 @@ static struct janus_json_parameter play_file_parameters[] = { static struct janus_json_parameter checkstop_file_parameters[] = { {"file_id", JSON_STRING, JANUS_JSON_PARAM_REQUIRED} }; +#endif static struct janus_json_parameter suspend_parameters[] = { {"pause_events", JANUS_JSON_BOOL, 0}, {"stop_record", JANUS_JSON_BOOL, 0}, @@ -5421,6 +5423,12 @@ static json_t *janus_audiobridge_process_synchronous_request(janus_audiobridge_s goto prepare_response; #endif } else if(!strcasecmp(request_text, "listannouncements")) { +#ifndef HAVE_LIBOGG + JANUS_LOG(LOG_VERB, "Listing announcements unsupported in this instance\n"); + error_code = JANUS_AUDIOBRIDGE_ERROR_INVALID_REQUEST; + g_snprintf(error_cause, 512, "Listing announcements unsupported in this instance"); + goto prepare_response; +#else /* List all announcements in a room */ if(!string_ids) { JANUS_VALIDATE_JSON_OBJECT(root, room_parameters, @@ -5491,6 +5499,7 @@ static json_t *janus_audiobridge_process_synchronous_request(janus_audiobridge_s json_object_set_new(response, "room", string_ids ? json_string(room_id_str) : json_integer(room_id)); json_object_set_new(response, "announcements", list); goto prepare_response; +#endif } else if(!strcasecmp(request_text, "stop_file")) { #ifndef HAVE_LIBOGG JANUS_LOG(LOG_VERB, "Playing files unsupported in this instance\n");