From 70d07d8026f65dfdb2ef15034aca58bb56f552f2 Mon Sep 17 00:00:00 2001 From: Bill Currie Date: Sun, 19 Nov 2023 16:40:24 +0900 Subject: [PATCH] [quakefs] Document that QFS_LoadFile closes the file In the end, I decided that the behavior isn't so bad, but it does need to be documented. Closes #34 --- include/QF/quakefs.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/include/QF/quakefs.h b/include/QF/quakefs.h index 91f7cb440..17b4f4a53 100644 --- a/include/QF/quakefs.h +++ b/include/QF/quakefs.h @@ -252,6 +252,10 @@ QFile *QFS_FOpenFile (const char *filename); data. Use 0. \return Pointer to the file's data, or NULL on error. \todo remove \a usehunk + + \note The file is closed on return as any error is either file not found + (\a file is null) or there was a memory allocation error (bigger + problems). */ byte *QFS_LoadFile (QFile *file, int usehunk);