RENAMED: GetFileSize() to GetFileLength()

`GetFileSize()` conflicts with the infamous `windows.h`
This commit is contained in:
Ray 2022-01-28 00:23:28 +01:00
parent 0f00c41aad
commit d38fe92c3f
2 changed files with 4 additions and 3 deletions

View file

@ -1041,7 +1041,7 @@ RLAPI bool SaveFileText(const char *fileName, char *text); // Save text d
RLAPI bool FileExists(const char *fileName); // Check if file exists RLAPI bool FileExists(const char *fileName); // Check if file exists
RLAPI bool DirectoryExists(const char *dirPath); // Check if a directory path exists RLAPI bool DirectoryExists(const char *dirPath); // Check if a directory path exists
RLAPI bool IsFileExtension(const char *fileName, const char *ext); // Check file extension (including point: .png, .wav) RLAPI bool IsFileExtension(const char *fileName, const char *ext); // Check file extension (including point: .png, .wav)
RLAPI int GetFileSize(const char *fileName); // Get file size in bytes RLAPI int GetFileLength(const char *fileName); // Get file length in bytes (NOTE: GetFileSize() conflicts with windows.h)
RLAPI const char *GetFileExtension(const char *fileName); // Get pointer to extension for a filename string (includes dot: '.png') RLAPI const char *GetFileExtension(const char *fileName); // Get pointer to extension for a filename string (includes dot: '.png')
RLAPI const char *GetFileName(const char *filePath); // Get pointer to filename for a path string RLAPI const char *GetFileName(const char *filePath); // Get pointer to filename for a path string
RLAPI const char *GetFileNameWithoutExt(const char *filePath); // Get filename string without extension (uses static string) RLAPI const char *GetFileNameWithoutExt(const char *filePath); // Get filename string without extension (uses static string)

View file

@ -2851,8 +2851,9 @@ bool DirectoryExists(const char *dirPath)
return result; return result;
} }
// Get file size in bytes // Get file length in bytes
int GetFileSize(const char *fileName) // NOTE: GetFileSize() conflicts with windows.h
int GetFileLength(const char *fileName)
{ {
int size = 0; int size = 0;