From: Wouter Wijngaards Date: Tue, 7 Apr 2009 13:10:17 +0000 (+0000) Subject: Escape spaces in printed domain names. X-Git-Tag: release-1.6.0~79 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=80a70976bf60cffa4d10cecb2064ca03e46b2cb9;p=thirdparty%2Fldns.git Escape spaces in printed domain names. --- diff --git a/host2str.c b/host2str.c index caef5de9..4e2c6c5b 100644 --- a/host2str.c +++ b/host2str.c @@ -251,8 +251,7 @@ ldns_rdf2buffer_str_dname(ldns_buffer *output, const ldns_rdf *dname) data[src_pos] == '(' || data[src_pos] == ')') { ldns_buffer_printf(output, "\\%c", data[src_pos]); - /* isprint!? */ - } else if (!isprint((int) data[src_pos])) { + } else if (!isgraph((int) data[src_pos])) { ldns_buffer_printf(output, "\\%03u", data[src_pos]); } else {