---
title: "CFBundlePreflightExecutable(_:_:)"
framework: corefoundation
role: symbol
role_heading: Function
path: "corefoundation/cfbundlepreflightexecutable(_:_:)"
---

# CFBundlePreflightExecutable(_:_:)

Returns a Boolean value that indicates whether a given bundle is loaded or appears to be loadable.

## Declaration

```swift
func CFBundlePreflightExecutable(_ bundle: CFBundle!, _ error: UnsafeMutablePointer<Unmanaged<CFError>?>!) -> Bool
```

## Parameters

- `bundle`: The bundle to examine.
- `error`: Upon return, if an error occurs contains a CFError that describes the problem. Ownership follows the https://developer.apple.com/library/archive/documentation/CoreFoundation/Conceptual/CFMemoryMgmt/Concepts/Ownership.html#//apple_ref/doc/uid/20001148-103029.

## Return Value

Return Value true if bundle is loaded or upon inspection appears to be loadable, otherwise false.

## Discussion

Discussion If this function returns true, this does not mean that the bundle is definitively loadable, since it may fail to load due to link errors or other problems not readily detectable.

## See Also

### Loading and Unloading a Bundle

- [CFBundleIsExecutableLoaded(_:)](corefoundation/cfbundleisexecutableloaded(_:).md)
- [CFBundleLoadExecutable(_:)](corefoundation/cfbundleloadexecutable(_:).md)
- [CFBundleLoadExecutableAndReturnError(_:_:)](corefoundation/cfbundleloadexecutableandreturnerror(_:_:).md)
- [CFBundleUnloadExecutable(_:)](corefoundation/cfbundleunloadexecutable(_:).md)
