From 04b02d4d5af76acb607d26939214240cbc15e15d Mon Sep 17 00:00:00 2001 From: Gergely Polonkai Date: Fri, 22 Jan 2016 16:00:20 +0100 Subject: [PATCH] Implement MatrixAPI.get_turn_server --- src/matrix-http-api.c | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/src/matrix-http-api.c b/src/matrix-http-api.c index ca1548b..2580b51 100644 --- a/src/matrix-http-api.c +++ b/src/matrix-http-api.c @@ -2739,6 +2739,19 @@ i_add_room_tag(MatrixAPI *api, g_free(path); } +static void +i_get_turn_server(MatrixAPI *api, + MatrixAPICallback callback, + gpointer user_data, + GError **error) +{ + _send(MATRIX_HTTP_API(api), + callback, user_data, + CALL_API, + "GET", "void/turnServer", NULL, NULL, NULL, NULL, + FALSE, error); +} + static void matrix_http_api_matrix_api_init(MatrixAPIInterface *iface) { @@ -2831,7 +2844,7 @@ matrix_http_api_matrix_api_init(MatrixAPIInterface *iface) iface->add_room_tag = i_add_room_tag; /* VoIP */ - iface->get_turn_server = NULL; + iface->get_turn_server = i_get_turn_server; /* Non-spec methods */ iface->abort_pending = NULL;