From: W.C.A. Wijngaards Date: Wed, 5 Feb 2014 16:15:08 +0000 (+0100) Subject: fix host2str for SERVICE and WKS X-Git-Tag: release-1.7.0~4 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=fc30bd04dd5cbabe2b6b51bafd46a4713ff30b14;p=thirdparty%2Fldns.git fix host2str for SERVICE and WKS --- diff --git a/host2str.c b/host2str.c index e2c936ba..b4970b1e 100644 --- a/host2str.c +++ b/host2str.c @@ -820,7 +820,7 @@ ldns_rdf2buffer_str_wks(ldns_buffer *output, const ldns_rdf *rdf) #endif for (current_service = 0; - current_service < ldns_rdf_size(rdf) * 7; current_service++) { + current_service < (ldns_rdf_size(rdf)-1)*8; current_service++) { if (ldns_get_bit(&(ldns_rdf_data(rdf)[1]), current_service)) { service = getservbyport((int) htons(current_service), proto_name);