This is to fix issue #145 (partially it turns out ;-) )
Currently ServiceInfo only contains sub_domain info if the query targets the subtype. The sub_domain is None if it is generated for querying the parent service type.
Part of the reason is that we only store mappings from PTR to instance SRV, not the other way. Both parent type PTR and subtype PTR points to the same instance SRV. When querying the parent PTR, we wouldn't know about the subtype PTR from the instance SRV. This patch is to make the reverse lookup possible.
This is to fix issue #145 (partially it turns out ;-) )
Currently
ServiceInfo
only containssub_domain
info if the query targets the subtype. Thesub_domain
isNone
if it is generated for querying the parent service type.Part of the reason is that we only store mappings from PTR to instance SRV, not the other way. Both parent type PTR and subtype PTR points to the same instance SRV. When querying the parent PTR, we wouldn't know about the subtype PTR from the instance SRV. This patch is to make the reverse lookup possible.