-
Notifications
You must be signed in to change notification settings - Fork 50
MTY_ReadFile
chrisd1100 edited this page Aug 25, 2022
·
1 revision
Read the entire contents of a file.
This function reads the file in binary mode.
void *MTY_ReadFile(
const char * path,
size_t * size
);
path
(const char *
)
Path to the file.
size
(size_t *
)
Set to the size in bytes of the returned buffer.
void *
The buffer always has its final byte set to 0, allowing you to treat it like a string. This extra byte is not counted in the returned size
.
On failure, NULL
is returned. Call MTY_GetLog
for details.