summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--jni/Android.mk3
-rw-r--r--openvpn/Android.mk5
-rw-r--r--src/de/blinkt/openvpn/OpenVpnService.java4
3 files changed, 8 insertions, 4 deletions
diff --git a/jni/Android.mk b/jni/Android.mk
index 283be302..faeedd44 100644
--- a/jni/Android.mk
+++ b/jni/Android.mk
@@ -6,7 +6,10 @@ include lzo/Android.mk
include openssl/Android.mk
ifneq ($(TARGET_ARCH),mips)
+WITH_BREAKPAD=1
include google-breakpad/android/google_breakpad/Android.mk
+else
+WITH_BREAKPAD=0
endif
include openvpn/Android.mk
diff --git a/openvpn/Android.mk b/openvpn/Android.mk
index c68bcccf..23e24448 100644
--- a/openvpn/Android.mk
+++ b/openvpn/Android.mk
@@ -11,7 +11,7 @@ LOCAL_SHARED_LIBRARIES := libssl libcrypto
LOCAL_CFLAGS= -DHAVE_CONFIG_H -DTARGET_ABI=\"${TARGET_ABI}\"
LOCAL_STATIC_LIBRARIES := liblzo-static
-ifneq ($(TARGET_ARCH),mips)
+ifeq ($(WITH_BREAKPAD),1)
LOCAL_STATIC_LIBRARIES += breakpad_client
LOCAL_CFLAGS += -DGOOGLE_BREAKPAD=1
endif
@@ -90,7 +90,8 @@ LOCAL_SRC_FILES:= \
src/openvpn/ssl_verify_polarssl.c \
src/openvpn/status.c \
src/openvpn/tun.c
-ifneq ($(TARGET_ARCH),mips)
+
+ifeq ($(WITH_BREAKPAD),1)
LOCAL_SRC_FILES+=src/openvpn/breakpad.cpp
endif
diff --git a/src/de/blinkt/openvpn/OpenVpnService.java b/src/de/blinkt/openvpn/OpenVpnService.java
index c73a1556..241bf774 100644
--- a/src/de/blinkt/openvpn/OpenVpnService.java
+++ b/src/de/blinkt/openvpn/OpenVpnService.java
@@ -233,14 +233,14 @@ public class OpenVpnService extends VpnService implements StateListener, Callbac
}
- void registerNetworkStateReceiver(OpenVPNMangement magnagement) {
+ synchronized void registerNetworkStateReceiver(OpenVPNMangement magnagement) {
// Registers BroadcastReceiver to track network connection changes.
IntentFilter filter = new IntentFilter(ConnectivityManager.CONNECTIVITY_ACTION);
mNetworkStateReceiver = new NetworkSateReceiver(magnagement);
this.registerReceiver(mNetworkStateReceiver, filter);
}
- void unregisterNetworkStateReceiver() {
+ synchronized void unregisterNetworkStateReceiver() {
if(mNetworkStateReceiver!=null)
this.unregisterReceiver(mNetworkStateReceiver);
mNetworkStateReceiver=null;