bool ex_fsys_issymlink ( const char *_path ) { #if 0 PHYSFS_Stat stat; if ( PHYSFS_stat( _path, &stat ) == 0 ) { ex_error ( "error: %s", PHYSFS_getLastError() ); return false; } return (stat.filetype == PHYSFS_FILETYPE_SYMLINK); #else return PHYSFS_isSymbolicLink(_path); #endif }
static int cmd_issymlink(char *args) { int rc; if (*args == '\"') { args++; args[strlen(args) - 1] = '\0'; } /* if */ rc = PHYSFS_isSymbolicLink(args); printf("File %s a symlink.\n", rc ? "is" : "is NOT"); return(1); } /* cmd_issymlink */
static int Lua_FS_isSymbolicLink(lua_State *L) { const char *filename = luaL_checkstring(L, 1); lua_pushboolean(L, PHYSFS_isSymbolicLink(filename)); return 1; }
bool isSymbolicLink(const string& filename) { return PHYSFS_isSymbolicLink(filename.c_str()); }
bool isSymbolicLink(const char* filename) { return PHYSFS_isSymbolicLink(filename); }
bool Resources::isSymbolicLink(const char* filename) { return PHYSFS_isSymbolicLink(filename); }
bool isSymbolicLink(const std::string& path) { return PHYSFS_isSymbolicLink(path.c_str()) != 0; }