From: Jaroslav Kysela Date: Fri, 29 May 2015 16:06:29 +0000 (+0200) Subject: HTSP: show default language settings in the hello message X-Git-Tag: v4.2.1~2424 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6c6a7970db0afaf359e47f309e3b64625644f9ed;p=thirdparty%2Ftvheadend.git HTSP: show default language settings in the hello message --- diff --git a/src/htsp_server.c b/src/htsp_server.c index 2a5dea122..0886ce235 100644 --- a/src/htsp_server.c +++ b/src/htsp_server.c @@ -18,6 +18,7 @@ #include "tvheadend.h" #include "atomic.h" +#include "config.h" #include "channels.h" #include "subscriptions.h" #include "tcp.h" @@ -966,7 +967,7 @@ htsp_method_hello(htsp_connection_t *htsp, htsmsg_t *in) { htsmsg_t *r; uint32_t v; - const char *name; + const char *name, *lang; if(htsmsg_get_u32(in, "htspversion", &v)) return htsp_error("Missing argument 'htspversion'"); @@ -987,6 +988,9 @@ htsp_method_hello(htsp_connection_t *htsp, htsmsg_t *in) htsmsg_add_bin(r, "challenge", htsp->htsp_challenge, 32); if (tvheadend_webroot) htsmsg_add_str(r, "webroot", tvheadend_webroot); + lang = config_get_language(); + if (lang) + htsmsg_add_str(r, "language", lang); /* Capabilities */ htsmsg_add_msg(r, "servercapability", tvheadend_capabilities_list(1));