BUF_ERASE(3) - Library Functions Manual
buf_erase - erase a portion of the string
buf_erase(struct buf *b, size_t pos, size_t count);
Remove count number of character in the buffer specified by b starting at pos.
It is possible to pass -1 as count parameter to remove the remaining text until the end of the string.
Undefined behavior may occur if the pos argument is outside of the buffer bounds.
The libbuf library was written by David Demelier <email@example.com>
macOS 12.3 - October 29, 2019-2022