Correctly handle query name parsing

This change fixes https://github.com/notwaldorf/cat-dns/issues/4 . Instead of assuming
that a queryname ends 4 bytes from the end of a query, this change computes the query
name length by counting the length of each label in the query. cat-dns now works with
EDNS0 options.

Tested with:

     dig +bufsize=4096 www.example.com @localhost
     dig +bufsize=4096 . @localhos