aboutsummaryrefslogtreecommitdiff
path: root/include/mgl/system/fileutils.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/mgl/system/fileutils.h')
-rw-r--r--include/mgl/system/fileutils.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/include/mgl/system/fileutils.h b/include/mgl/system/fileutils.h
index 71af147..7696679 100644
--- a/include/mgl/system/fileutils.h
+++ b/include/mgl/system/fileutils.h
@@ -2,13 +2,19 @@
#define MGL_FILEUTILS_H
#include <stddef.h>
+#include <stdbool.h>
typedef struct {
unsigned char *data;
size_t size;
} mgl_filedata;
-int mgl_load_file(const char *filepath, mgl_filedata *filedata);
+typedef struct {
+ bool null_terminated; /* false by default */
+} mgl_file_load_options;
+
+/* |load_options| can be null, in which case the default options are used */
+int mgl_load_file(const char *filepath, mgl_filedata *filedata, mgl_file_load_options *load_options);
void mgl_filedata_free(mgl_filedata *self);
#endif /* MGL_FILEUTILS_H */