123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139 |
- #include <sys/stat.h>
- #include <sys/sysconf.h>
- #include <unistd.h>
- #include <errno.h>
- #include <android/asset_manager.h>
- #include <android/asset_manager_jni.h>
- #include "CFTTFileSystem_Android.h"
- #include "CFTTFile_Android.h"
- #include "CFTTFileSystem_APKX.h"
- #include "CFTTFile_AndroidDocs.h"
- #include "str_conv.h"
- #include "memctrl.h"
- CFTTFile_AsyncQueue *CFTTFileSystem_Android::ms_pAsyncQueue = nullptr; //005CDFCC
- bool CFTTFileSystem_Android::s_bHaveExpansionFile = false;
- MYSTATIC char *ExpansionPath_5CE3D4 = nullptr;
- MYSTATIC AAssetManager *pAAssetManager_5CDFD0; //005CDFD0
- char dir_5CDFD4[1024];
- //-------------------------------------------------------------------------------------------------
- //0026C608 //^_-
- CFTTFileSystem_Android::CFTTFileSystem_Android(const char *a2, const char *ptype) {
- }
- //-------------------------------------------------------------------------------------------------
- //0026C694 0026C6B8 //^_^
- CFTTFileSystem_Android::~CFTTFileSystem_Android() {
- }
- //-------------------------------------------------------------------------------------------------
- //0026C6C6 //^_^
- bool CFTTFileSystem_Android::GetAbsoluteFilename(char const *filepath,
- char *pOutputName,
- uint outpue_len) {
- bool dret = false;
- return dret;
- }
- //-------------------------------------------------------------------------------------------------
- //0026C81E //^_^
- CFTTFile *CFTTFileSystem_Android::Open(char const *filepath,
- uint a3,
- EFTTMemHeapID eHeapId) {
- return 0;
- }
- //-------------------------------------------------------------------------------------------------
- //0026C852 //^_^
- EFTTError CFTTFileSystem_Android::Delete(char const *filepath) {
- EFTTError derror;
- return derror;
- }
- //-------------------------------------------------------------------------------------------------
- //0026C898 //其中的while循环被编译器优化掉了
- EFTTError CFTTFileSystem_Android::Rename(char const *oldpath,
- char const *newpath,
- CFTTFileSystem *pFileSystem_arg) {
- EFTTError errRet;
- return errRet;
- }
- //-------------------------------------------------------------------------------------------------
- //0026C90C //^_^ 唯有这个函数有栈保护
- EFTTError CFTTFileSystem_Android::Copy(char const *src, char const *dst, bool) {
- EFTTError eret;
- return eret;
- }
- //-------------------------------------------------------------------------------------------------
- //0026C9D0 //^_^
- EFTTError CFTTFileSystem_Android::OpenDir(char const *pDir,
- CFTTFileIterator **ppFileIt) {
- EFTTError eret;
- // loc_26CA7C
- return eret;
- }
- //-------------------------------------------------------------------------------------------------
- //0026CAAC //^_^
- bool CFTTFileSystem_Android::FileExistsFS(char const *filepath) {
- bool bret = false;
- return bret;
- }
- //-------------------------------------------------------------------------------------------------
- // AAsset* AAssetManager_open(AAssetManager* mgr, const char* filename, int mode);
- //0026CB00 //^_^
- EFTTError CFTTFileSystem_Android::GetAttributesFS(char const *filepath, TFTTFileAttributes *pAttr) {
- EFTTError err;
- return err;
- }
- //-------------------------------------------------------------------------------------------------
- //0026C548 //^_^
- char *CFTTFileSystem_Android::AndroidGetExpansionPath() {
- return ExpansionPath_5CE3D4;
- }
- //-------------------------------------------------------------------------------------------------
- //0026C520 //^_^ AAssetManager *arg_pAAssetManager
- void CFTTFileSystem_Android::AndroidSetAssetManager(void *arg_pAAssetManager) {
- LOGE("CFTTFileSystem_Android::AndroidSetAssetManager%p",arg_pAAssetManager);
- }
- //-------------------------------------------------------------------------------------------------
- //0026C554 //^_^
- void CFTTFileSystem_Android::AndroidSetExpansionPath(char const *filepath) {
- LOGE("AndroidSetExpansionPath%p%s",filepath,filepath);
- }
- //-------------------------------------------------------------------------------------------------
- //0026C52C //^_^
- int CFTTFileSystem_Android::AndroidSetExternalFilesDir(char const *dirpath) {
- // memset(dir_5CDFD4, 0, 1024);
- LOGE("AndroidSetExternalFilesDir%p%s",dirpath,dirpath);
- return 0;
- }
- //-------------------------------------------------------------------------------------------------
- //0026C818 //^_^
- void CFTTFileSystem_Android::CloseAsset(AAsset *a2) {
- }
- //-------------------------------------------------------------------------------------------------
- //0026C480 //^_-
- EFTTError CFTTFileSystem_Android::ErrorInternal(int errid, CFTTFile_Android *pFile, char const *name) {
- return EFTTError_0;
- }
- //-------------------------------------------------------------------------------------------------
- //0026C574 //^_^
- void CFTTFileSystem_Android::InitExpansionFilesystem() {
- }
- //-------------------------------------------------------------------------------------------------
- //0026C7E0 //^_^
- AAsset *CFTTFileSystem_Android::OpenAsset(char const *a2) {
- return 0;
- }
- //-------------------------------------------------------------------------------------------------
- //0026C708 //^_-
- CFTTFile *CFTTFileSystem_Android::Open_Common(char const *filepath,
- uint dMod,
- EFTTMemHeapID eHeapId) {
- // loc_26C7A2
- return nullptr;
- }
- //-------------------------------------------------------------------------------------------------
- //0026CB74 //^_^
- void CFTTFileSystem_Android::Shutdown() {
- }
- //-------------------------------------------------------------------------------------------------
|