diff --git a/app/build.gradle b/app/build.gradle index 583062c..de39cab 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -18,8 +18,8 @@ model { applicationId = "org.cipherdyne.fwknop2" minSdkVersion.apiLevel = 15 targetSdkVersion.apiLevel = 23 - versionCode = 22 - versionName = "1.2" + versionCode = 23 + versionName = "1.2.1" } } android.buildTypes { diff --git a/app/src/main/java/biz/incomsystems/fwknop2/DBHelper.java b/app/src/main/java/biz/incomsystems/fwknop2/DBHelper.java index c1d9c6e..4729974 100644 --- a/app/src/main/java/biz/incomsystems/fwknop2/DBHelper.java +++ b/app/src/main/java/biz/incomsystems/fwknop2/DBHelper.java @@ -203,6 +203,52 @@ public Config getConfig (String nick) { CurrentIndex.close(); + // There was at least one reported crash related to an unexpected null returned from this function. + // This is a bit of a heavyhanded solution. (OK, it's an ugly hack) + + if (config.ACCESS_IP == null) { + config.ACCESS_IP = ""; + } + if (config.PORTS == null) { + config.PORTS = ""; + } + if (config.SERVER_IP == null) { + config.SERVER_IP = ""; + } + if (config.SERVER_PORT == null) { + config.SERVER_PORT = ""; + } + if (config.SERVER_TIMEOUT == null) { + config.SERVER_TIMEOUT = ""; + } + if (config.KEY == null) { + config.KEY = ""; + } + if (config.HMAC == null) { + config.HMAC = ""; + } + if (config.NAT_IP == null) { + config.NAT_IP = ""; + } + if (config.NAT_PORT == null) { + config.NAT_PORT = ""; + } + if (config.SERVER_CMD == null) { + config.SERVER_CMD = ""; + } + if (config.SSH_CMD == null) { + config.SSH_CMD = ""; + } + if (config.PROTOCOL == null) { + config.PROTOCOL = ""; + } + if (config.DIGEST_TYPE == null) { + config.DIGEST_TYPE = ""; + } + if (config.HMAC_TYPE == null) { + config.HMAC_TYPE = ""; + } + return config; } } diff --git a/app/src/main/jni/Application.mk b/app/src/main/jni/Application.mk deleted file mode 100644 index b222374..0000000 --- a/app/src/main/jni/Application.mk +++ /dev/null @@ -1 +0,0 @@ -APP_PLATFORM=android-19 \ No newline at end of file