vfs: check userland buffers before reading them.
[haiku.git] / src / add-ons / media / plugins / ape_reader / MAClib / GlobalFunctions.h
blob823ea93f4959907d76b4057bb9bd764a32e37279
1 #ifndef APE_GLOBALFUNCTIONS_H
2 #define APE_GLOBALFUNCTIONS_H
4 /*************************************************************************************
5 Definitions
6 *************************************************************************************/
7 class CIO;
9 /*************************************************************************************
10 Read / Write from an IO source and return failure if the number of bytes specified
11 isn't read or written
12 *************************************************************************************/
13 int ReadSafe(CIO * pIO, void * pBuffer, int nBytes);
14 int WriteSafe(CIO * pIO, void * pBuffer, int nBytes);
16 /*************************************************************************************
17 Checks for the existence of a file
18 *************************************************************************************/
19 BOOL FileExists(wchar_t * pFilename);
21 #endif // #ifndef APE_GLOBALFUNCTIONS_H