copyStringz

private fnconst(char) * copyStringz(scope const(char)[] source, scope char[] buffer) @trusted nothrow

Copy a D string slice to a null-terminated C string buffer.

Parameters

sourceSource string slice.
bufferDestination buffer.

Returns

Pointer to the null-terminated string, or null if buffer is too small.