physfs_internal.h
changeset 39 bc29e1ee7ef6
parent 30 c9cc9b79112e
child 41 ff60d39d0862
equal deleted inserted replaced
38:feb16343f44c 39:bc29e1ee7ef6
   247 #define ERR_NO_WRITE_DIR         "Write directory is not set"
   247 #define ERR_NO_WRITE_DIR         "Write directory is not set"
   248 #define ERR_NO_SUCH_FILE         "No such file"
   248 #define ERR_NO_SUCH_FILE         "No such file"
   249 #define ERR_PAST_EOF             "Past end of file"
   249 #define ERR_PAST_EOF             "Past end of file"
   250 #define ERR_ARC_IS_READ_ONLY     "Archive is read-only"
   250 #define ERR_ARC_IS_READ_ONLY     "Archive is read-only"
   251 #define ERR_IO_ERROR             "I/O error"
   251 #define ERR_IO_ERROR             "I/O error"
       
   252 #define ERR_CANT_SET_WRITE_DIR   "Can't set write directory."
       
   253 
   252 
   254 
   253 /*
   255 /*
   254  * Call this to set the message returned by PHYSFS_getLastError().
   256  * Call this to set the message returned by PHYSFS_getLastError().
   255  *  Please only use the ERR_* constants above, or add new constants to the
   257  *  Please only use the ERR_* constants above, or add new constants to the
   256  *  above group, but I want these all in one place.
   258  *  above group, but I want these all in one place.
   415  *  Return -1 if you can't do it, and call __PHYSFS_setError().
   417  *  Return -1 if you can't do it, and call __PHYSFS_setError().
   416  */
   418  */
   417 int __PHYSFS_platformFileLength(FILE *handle);
   419 int __PHYSFS_platformFileLength(FILE *handle);
   418 
   420 
   419 
   421 
       
   422 /*
       
   423  * Get the current working directory. The return value should be an
       
   424  *  absolute path in platform-dependent notation. The caller will deallocate
       
   425  *  the return value with the standard C runtime free() function when it
       
   426  *  is done with it.
       
   427  * On error, return NULL and set the error message.
       
   428  */
       
   429 char *__PHYSFS_platformCurrentDir(void);
       
   430 
       
   431 
       
   432 /*
       
   433  * Get the real physical path to a file. (path) is specified in
       
   434  *  platform-dependent notation, as should your return value be.
       
   435  *  All relative paths should be removed, leaving you with an absolute
       
   436  *  path. Symlinks should be resolved, too, so that the returned value is
       
   437  *  the most direct path to a file.
       
   438  * The return value will be deallocated with the standard C runtime free()
       
   439  *  function when the caller is done with it.
       
   440  * On error, return NULL and set the error message.
       
   441  */
       
   442 char *__PHYSFS_platformRealPath(const char *path);
       
   443 
       
   444 
   420 #ifdef __cplusplus
   445 #ifdef __cplusplus
   421 extern "C" {
   446 extern "C" {
   422 #endif
   447 #endif
   423 
   448 
   424 #endif
   449 #endif