diff --git a/increment.sh b/increment.sh index 8167b8e..bafbeb7 100755 --- a/increment.sh +++ b/increment.sh @@ -3,5 +3,5 @@ BUILD_NUMBER_STR=$(cat .buildnum) BUILD_NUMBER=$((BUILD_NUMBER_STR + 1)) echo $BUILD_NUMBER > .buildnum -echo "#define ZTSDK_BUILD_VERSION " $BUILD_NUMBER > src/SDK_LocalBuild.h +echo "#define ZTSDK_BUILD_VERSION " $BUILD_NUMBER > src/build.h echo $BUILD_NUMBER diff --git a/integrations/apple/ZeroTierSDK_Apple/ZeroTierSDK_Apple.xcodeproj/project.pbxproj b/integrations/apple/ZeroTierSDK_Apple/ZeroTierSDK_Apple.xcodeproj/project.pbxproj index 422a25e..991db49 100644 --- a/integrations/apple/ZeroTierSDK_Apple/ZeroTierSDK_Apple.xcodeproj/project.pbxproj +++ b/integrations/apple/ZeroTierSDK_Apple/ZeroTierSDK_Apple.xcodeproj/project.pbxproj @@ -1317,7 +1317,6 @@ "-DSDK_DEBUG", "-DSDK", "-D__IOS__", - "-DLWIP_DEBUG", "-DSDK_BUNDLED", "-DUSING_BRIDGING_HEADER", "-DSDK_IPV4", diff --git a/src/service.cpp b/src/service.cpp index 8274ece..893b435 100644 --- a/src/service.cpp +++ b/src/service.cpp @@ -427,6 +427,15 @@ void *zts_start_core_service(void *thread_id) { // set_intercept_status(INTERCEPT_DISABLED); // Ignore network calls from ZT service //#endif + #if defined(__IOS__) + // Go to the app's data directory so we can shorten the sun_path we bind to + char current_dir[MAX_DIR_SZ]; + getcwd(current_dir, MAX_DIR_SZ); + std::string targetDir = homeDir; // + "/../../"; + chdir(targetDir.c_str()); + homeDir = localHomeDir; + #endif + #if defined(__UNITY_3D__) char current_dir[MAX_DIR_SZ]; getcwd(current_dir, MAX_DIR_SZ); @@ -467,6 +476,7 @@ void *zts_start_core_service(void *thread_id) { if ((*pi != ".")&&(*pi != "..")) { if (!ZeroTier::OSUtils::mkdir(ptmp)) { DEBUG_ERROR("home path does not exist, and could not create"); + perror("error\n"); } } } @@ -476,14 +486,7 @@ void *zts_start_core_service(void *thread_id) { return NULL; } - #if defined(__IOS__) - // Go to the app's data directory so we can shorten the sun_path we bind to - char current_dir[MAX_DIR_SZ]; - getcwd(current_dir, MAX_DIR_SZ); - std::string targetDir = homeDir + "/../../"; - chdir(targetDir.c_str()); - homeDir = localHomeDir; - #endif + //chdir(current_dir); // Return to previous current working directory (at the request of Unity3D) #if defined(__UNITY_3D__) diff --git a/src/tap.cpp b/src/tap.cpp index fb3b8c2..e0606bb 100644 --- a/src/tap.cpp +++ b/src/tap.cpp @@ -695,8 +695,6 @@ NetconEthernetTap::NetconEthernetTap( // SIP-0 // Load and initialize network stack library #if defined(SDK_LWIP) - DEBUG_INFO("Did I get here?"); - Utils::snprintf(stackPath,sizeof(stackPath),"%s%sliblwip.so",homePath,ZT_PATH_SEPARATOR_S); lwipstack = new lwIP_stack(stackPath); if(!lwipstack) {