mirror of
https://github.com/ddnet/ddnet.git
synced 2024-11-13 03:28:19 +00:00
c7fb013607
- `io_read_all` reads all bytes from a file handle into a new buffer. It should only need one allocation per file in cases where the actual file size matches the expected file size. Otherwise it falls back to doubling the buffer size if the actual file size is larger than expected to avoid TOCTOU problems. - `io_read_all_str` reads all bytes from a file handle into a new buffer and also ensures that the buffer is null-terminated and contains no other null-characters. - `mem_has_null` is a utility used by `io_read_all_str` to ensure that no null-characters exist in the bytes read from the file. |
||
---|---|---|
.. | ||
tl | ||
unicode | ||
color.h | ||
detect.h | ||
dynamic.h | ||
hash.cpp | ||
hash.h | ||
hash_bundled.cpp | ||
hash_ctxt.h | ||
hash_libtomcrypt.cpp | ||
hash_openssl.cpp | ||
lock_scope.h | ||
log.cpp | ||
log.h | ||
logger.h | ||
math.h | ||
system.cpp | ||
system.h | ||
vmath.h |