Skip to main content

ghostty_alloc

Function ghostty_alloc 

Source
pub unsafe extern "C" fn ghostty_alloc(
    allocator: *const Allocator,
    len: usize,
) -> *mut u8
Expand description

Allocate a buffer of len bytes.

Uses the provided allocator, or the default allocator if NULL is passed. The returned buffer must be freed with ghostty_free() using the same allocator.