From: User Decke Date: Mon, 6 May 2013 13:57:14 +0000 (+0200) Subject: Fix printf format modifier to build properly with CLANG. X-Git-Tag: v3.9~46^2~5 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=138e73eb26f7174ec610c6e3355bced4f00474bb;p=thirdparty%2Ftvheadend.git Fix printf format modifier to build properly with CLANG. src/htsp_server.c:485:55: error: format specifies type 'short' but the argument has type 'int' [-Werror,-Wformat] p += snprintf(url+p, sizeof(url)-p, "%s%s%s:%hd%s", ~~^ %d --- diff --git a/src/htsp_server.c b/src/htsp_server.c index 0261e5d43..1931fb838 100644 --- a/src/htsp_server.c +++ b/src/htsp_server.c @@ -527,7 +527,7 @@ htsp_build_channel(channel_t *ch, const char *method, htsp_connection_t *htsp) tcp_get_ip_str((struct sockaddr*)&addr, buf, 50); strcpy(url, "http://"); p = strlen(url); - p += snprintf(url+p, sizeof(url)-p, "%s%s%s:%hd%s", + p += snprintf(url+p, sizeof(url)-p, "%s%s%s:%d%s", (addr.ss_family == AF_INET6)?"[":"", buf, (addr.ss_family == AF_INET6)?"]":"",