---
title: kCFAllocatorMalloc
framework: corefoundation
role: symbol
role_heading: Global Variable
path: corefoundation/kcfallocatormalloc
---

# kCFAllocatorMalloc

This allocator uses malloc(), realloc(), and free().

## Declaration

```swift
let kCFAllocatorMalloc: CFAllocator!
```

## Discussion

Discussion Typically you should not use this allocator, use kCFAllocatorDefault instead. This allocator is useful as the bytesDeallocator in CFData or contentsDeallocator in CFString where the memory was obtained as a result  of malloc type functions.

## See Also

### Constants

- [kCFAllocatorDefault](corefoundation/kcfallocatordefault.md)
- [kCFAllocatorSystemDefault](corefoundation/kcfallocatorsystemdefault.md)
- [kCFAllocatorMallocZone](corefoundation/kcfallocatormalloczone.md)
- [kCFAllocatorNull](corefoundation/kcfallocatornull.md)
- [kCFAllocatorUseContext](corefoundation/kcfallocatorusecontext.md)
