---
title: "CFNetServiceBrowserInvalidate(_:)"
framework: cfnetwork
role: symbol
role_heading: Function
path: "cfnetwork/cfnetservicebrowserinvalidate(_:)"
---

# CFNetServiceBrowserInvalidate(_:)

Invalidates an instance of a Network Service browser object.

## Declaration

```swift
func CFNetServiceBrowserInvalidate(_ browser: CFNetServiceBrowser)
```

## Parameters

- `browser`: The CFNetServiceBrowser to invalidate, obtained by a previous call to doc://com.apple.cfnetwork/documentation/CFNetwork/CFNetServiceBrowserCreate(_:_:_:).

## Discussion

Discussion This function invalidates the specified instance of a Network Service browser object. Any searches using the specified instance that are in progress when this function is called are stopped. An invalidated browser cannot be scheduled on a run loop and its callback function is never called. Special Considerations This function is thread safe as long as another thread does not alter the same CFNetServiceBrowserRef at the same time.

## See Also

### Network Services

- [CFNetService](cfnetwork/cfnetservice.md)
- [CFNetServiceBrowser](cfnetwork/cfnetservicebrowser.md)
- [CFNetServiceBrowserFlags](cfnetwork/cfnetservicebrowserflags.md)
- [CFNetServiceMonitor](cfnetwork/cfnetservicemonitor.md)
- [CFNetServiceMonitorType](cfnetwork/cfnetservicemonitortype.md)
- [CFNetServiceClientContext](cfnetwork/cfnetserviceclientcontext.md)
- [CFNetServiceRegisterFlags](cfnetwork/cfnetserviceregisterflags.md)
- [CFNetServicesError](cfnetwork/cfnetserviceserror.md)
- [CFNetServiceBrowserScheduleWithRunLoop(_:_:_:)](cfnetwork/cfnetservicebrowserschedulewithrunloop(_:_:_:).md)
- [CFNetServiceBrowserCreate(_:_:_:)](cfnetwork/cfnetservicebrowsercreate(_:_:_:).md)
- [CFNetServiceBrowserGetTypeID()](cfnetwork/cfnetservicebrowsergettypeid().md)
- [CFNetServiceBrowserSearchForDomains(_:_:_:)](cfnetwork/cfnetservicebrowsersearchfordomains(_:_:_:).md)
- [CFNetServiceBrowserSearchForServices(_:_:_:_:)](cfnetwork/cfnetservicebrowsersearchforservices(_:_:_:_:).md)
- [CFNetServiceBrowserStopSearch(_:_:)](cfnetwork/cfnetservicebrowserstopsearch(_:_:).md)
- [CFNetServiceBrowserUnscheduleFromRunLoop(_:_:_:)](cfnetwork/cfnetservicebrowserunschedulefromrunloop(_:_:_:).md)
