From ea2964f5a168cb52d1b9f74a08f00c7c068c6649 Mon Sep 17 00:00:00 2001 From: ShadowNinja Date: Mon, 24 Aug 2015 17:00:06 -0400 Subject: Add seperate cache path This is set to the XDG cache path where possible. It's set to the app's cache path on Android. --- src/main.cpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'src/main.cpp') diff --git a/src/main.cpp b/src/main.cpp index 151ea7148..72daaef01 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -164,7 +164,13 @@ int main(int argc, char *argv[]) setup_log_params(cmd_args); porting::signal_handler_init(); + +#ifdef __ANDROID__ + porting::initAndroid(); + porting::initializePathsAndroid(); +#else porting::initializePaths(); +#endif if (!create_userdata_path()) { errorstream << "Cannot create user data directory" << std::endl; @@ -422,9 +428,6 @@ static bool create_userdata_path() bool success; #ifdef __ANDROID__ - porting::initAndroid(); - - porting::setExternalStorageDir(porting::jnienv); if (!fs::PathExists(porting::path_user)) { success = fs::CreateDir(porting::path_user); } else { @@ -436,9 +439,6 @@ static bool create_userdata_path() success = fs::CreateDir(porting::path_user); #endif - infostream << "path_share = " << porting::path_share << std::endl; - infostream << "path_user = " << porting::path_user << std::endl; - return success; } -- cgit v1.2.3