summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2006-05-04 21:50:44 +0000
committerLennart Poettering <lennart@poettering.net>2006-05-04 21:50:44 +0000
commitaffc2091e149b08220254a7f700a8be935d0cdde (patch)
treed581e1211817bed0d36f34662de383ce9bc05205
parente703146e3ed32199c5de2f5ad37c5ee23291871d (diff)
actually enforce that we never print more than 20 bytes from arbitrary records in avahi_record_to_string()
git-svn-id: file:///home/lennart/svn/public/avahi/trunk@1209 941a03a8-eaeb-0310-b9a0-b1bbd8fe43fe
-rw-r--r--avahi-core/rr.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/avahi-core/rr.c b/avahi-core/rr.c
index 46aa7a2..8b7fab7 100644
--- a/avahi-core/rr.c
+++ b/avahi-core/rr.c
@@ -303,7 +303,7 @@ char *avahi_record_to_string(const AvahiRecord *r) {
for (c = r->data.generic.data, n = r->data.generic.size, i = 0;
n > 0 && i < 20;
- c ++, n --) {
+ c ++, n --, i++) {
sprintf(e, " %02X", *c);
e = strchr(e, 0);