| 1450 | */ |
| 1451 | |
| 1452 | static void DNSSD_API |
| 1453 | browse_callback( |
| 1454 | DNSServiceRef sdRef, /* I - Service reference */ |
| 1455 | DNSServiceFlags flags, /* I - Option flags */ |
| 1456 | uint32_t interfaceIndex, /* I - Interface number */ |
| 1457 | DNSServiceErrorType errorCode, /* I - Error, if any */ |
| 1458 | const char *serviceName, /* I - Name of service/device */ |
| 1459 | const char *regtype, /* I - Type of service */ |
| 1460 | const char *replyDomain, /* I - Service domain */ |
| 1461 | void *context) /* I - Services array */ |
| 1462 | { |
| 1463 | /* |
| 1464 | * Only process "add" data... |
| 1465 | */ |
| 1466 | |
| 1467 | last_update = _cupsGetClock(); |
| 1468 | |
| 1469 | (void)sdRef; |
| 1470 | (void)interfaceIndex; |
| 1471 | |
| 1472 | if (errorCode != kDNSServiceErr_NoError || !(flags & kDNSServiceFlagsAdd)) |
| 1473 | return; |
| 1474 | |
| 1475 | /* |
| 1476 | * Get the device... |
| 1477 | */ |
| 1478 | |
| 1479 | get_service((cups_array_t *)context, serviceName, regtype, replyDomain); |
| 1480 | } |
| 1481 | |
| 1482 | |
| 1483 | /* |
nothing calls this directly
no test coverage detected