anchor.diff:  	    end
       end.
   
  +-spec query_record(domain(), rtype()) -> {ok, op_ref()} | {error, _}.
  +query_record(Domain, RType)
  +  when is_binary(Domain), is_binary(RType) ->
  +    case ensure_safe_rtype(RType) of
  +	{error, _} = Err -> Err;
  +	_ -> dnssd_server:query_record(Domain, RType)
  +    end;
  +query_record(Domain, RType)
  +  when ?IS_LIST_OR_BIN(Domain),
  +       ?IS_LIST_OR_BIN(RType) ->
  +    query_record(iolist_to_binary(Domain), iolist_to_binary(Domain)).
  +
   -ifdef(AVAHI).
   ensure_safe_name(<<>>) ->
       {ok, Hostname} = inet:gethostname(),
  
positive.code: -export([browse/1, browse/2]).
  -export([resolve/3, resolve_sync/3, resolve_sync/4]).
  -export([register/2, register/3, register/4, register/6]).
  
  -ifdef(TEST).
  -include_lib("eunit/include/eunit.hrl").
  
negative.code:     end;
  ensure_safe_type(_) ->
      {error, bad_type}.
  
  ensure_safe_rtype(<<"TXT">>) -> ok;
  ensure_safe_rtype(RType) ->
      {error, {bad_rtype, RType}}.
  
  parse_type_t(<<$_, Protocol/binary>>) ->
      parse_type_t(<<>>, Protocol).
  