[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-devel
Subject: Getting a hostname from Zeroconf
From: "Ian Monroe" <ian () monroe ! nu>
Date: 2006-07-07 1:10:29
Message-ID: f680fec50607061810n7c37840fk478baf0afedd366b () mail ! gmail ! com
[Download RAW message or body]
I'm implementing a DAAP client in Amarok. I asyncResolve the
RemoteService, and in that slot:
const DNSSD::RemoteService* service = static_cast<const
DNSSD::RemoteService*>(sender());
debug() << service->serviceName() << ' ' << service->hostName() << ' '
<< service->domain() << ' ' << service->type() << endl;
Prints out:
mt-daapd wasabi.local. local. _daap._tcp
Ian?s Music win2000.local. local. _daap._tcp
So the hostName is like wasabi.local. How do I get a valid hostname or
ip address out of that? Wasabi is a hostname that resolves normally,
but win2000 does not (both work with the Banshee DAAP client). The API
suggests using KResolver, but I can't make head or tails of its API.
Any ideas or pointers to existing code? I was looking through
zeroconf:/, but it is difficult to trace.
Thanks,
Ian Monroe
>> Visit http://mail.kde.org/mailman/listinfo/kde-devel#unsub to unsubscribe <<
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic