Exemplo n.º 1
0
bool Manager::startBrowsing()
{
    if( !m_linkLocalHandler )
        return false;

    if( m_browseRef )
        stopBrowsing();

    DNSServiceErrorType e = DNSServiceBrowse( &m_browseRef,
                            0,                              // flags, currently ignored
                            m_interface,                    // interface, 0 = any, -1 = local only
                            LINKLOCAL_SERVICE_TYPE.c_str(), // service type
                            m_domain.c_str(),               // domain, 0 = default domain(s)
                            &handleBrowseReply,             // callback
                            this );                         // context
    if ( e != kDNSServiceErr_NoError )
        return false;

    return true;
}
Exemplo n.º 2
0
QxtServiceBrowser::~QxtServiceBrowser() {
    if(isBrowsing())
        stopBrowsing();
}
Exemplo n.º 3
0
Manager::~Manager()
{
    deregisterService();
    stopBrowsing();
}