summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFederico Lucifredi <flucifredi@acm.org>2007-12-27 05:02:06 +0000
committerFederico Lucifredi <flucifredi@acm.org>2007-12-27 05:02:06 +0000
commitfab3ce2f8ccedb6a8e657317349071539c25667e (patch)
tree443a211a2753bc68ce1a0ee4e767aaee672b3b87
parentf0174295e48d59324286dc75e2b4058aa9e7f06b (diff)
test
git-svn-id: file:///home/lennart/svn/public/avahi/branches/federico@1636 941a03a8-eaeb-0310-b9a0-b1bbd8fe43fe
-rw-r--r--avahi-core/dns.c4
-rw-r--r--avahi-core/entry.c5
-rw-r--r--avahi-core/wide-area.c5
3 files changed, 11 insertions, 3 deletions
diff --git a/avahi-core/dns.c b/avahi-core/dns.c
index e69b88a..2e1aa26 100644
--- a/avahi-core/dns.c
+++ b/avahi-core/dns.c
@@ -193,8 +193,8 @@ uint8_t* avahi_dns_packet_append_name(AvahiDnsPacket *p, const char *name) {
if (!(t = (uint8_t*) avahi_dns_packet_extend(p, sizeof(uint16_t))))
return NULL;
- t[0] = (uint8_t) ((0xC000 | idx) >> 8);
- t[1] = (uint8_t) idx;
+ t[0] = (uint8_t) ((0xC000 | idx) >> 8);
+ t[1] = (uint8_t) idx;
return saved_ptr;
}
}
diff --git a/avahi-core/entry.c b/avahi-core/entry.c
index 5db8908..3e25c69 100644
--- a/avahi-core/entry.c
+++ b/avahi-core/entry.c
@@ -225,6 +225,11 @@ static AvahiEntry * server_add_internal(
/* may have to move lower into logic, for _new_ and _modified_ records only */
printf("+++ record of type %d named %s observed at entrypoint\n", r->key->type, r->key->name);
+ char[100] out;
+ int out_len = 100;
+ avahi_unescape_label("foo.com", 8, &out, &out_len);
+ printf("result: -%s-\n", out);
+
/* sketch publishing function */
/*wide_area_publish();*/
diff --git a/avahi-core/wide-area.c b/avahi-core/wide-area.c
index b2d2084..6195a03 100644
--- a/avahi-core/wide-area.c
+++ b/avahi-core/wide-area.c
@@ -800,7 +800,10 @@ AvahiRecord* tsig_sign_packet(const char* keyname, const char* key, unsigned key
return NULL;
}
- /*HMAC_Update(&ctx, <data/>, <length/>);*/ /*feed all the data to be hashed in */
+ /*feed all the data to be hashed in */
+ /*HMAC_Update(&ctx, <data/>, <length/>);*/
+ HMAC_Update(&ctx, p->data, p->size);
+ /* HMAC_Update(&ctx, CONTINUE */
HMAC_Final(&ctx, keyed_hash, &hash_length);
HMAC_cleanup(&ctx);