summaryrefslogtreecommitdiff
path: root/app/src/main/java/de/blinkt
diff options
context:
space:
mode:
authorcyBerta <cyberta@riseup.net>2021-12-11 01:47:09 +0100
committercyBerta <cyberta@riseup.net>2021-12-11 01:47:09 +0100
commit6949fc419d56ff6f657c78da61ea1eeed2169bd0 (patch)
tree88225a3d65bb470d9ac4ae12b6cab045666bc63a /app/src/main/java/de/blinkt
parent5ce549b5fa834283a82fd1e510f568aa0a8209ae (diff)
make trafficdata linked list in DevicecStateReceiver final and fix typo
Diffstat (limited to 'app/src/main/java/de/blinkt')
-rw-r--r--app/src/main/java/de/blinkt/openvpn/core/DeviceStateReceiver.java9
1 files changed, 5 insertions, 4 deletions
diff --git a/app/src/main/java/de/blinkt/openvpn/core/DeviceStateReceiver.java b/app/src/main/java/de/blinkt/openvpn/core/DeviceStateReceiver.java
index 13417a5a..2b0c785e 100644
--- a/app/src/main/java/de/blinkt/openvpn/core/DeviceStateReceiver.java
+++ b/app/src/main/java/de/blinkt/openvpn/core/DeviceStateReceiver.java
@@ -45,7 +45,7 @@ public class DeviceStateReceiver extends BroadcastReceiver implements ByteCountL
connectState userpause = connectState.SHOULDBECONNECTED;
private String lastStateMsg = null;
- private java.lang.Runnable mDelayDisconnectRunnable = new Runnable() {
+ private final java.lang.Runnable mDelayDisconnectRunnable = new Runnable() {
@Override
public void run() {
if (!(network == connectState.PENDINGDISCONNECT))
@@ -83,7 +83,7 @@ public class DeviceStateReceiver extends BroadcastReceiver implements ByteCountL
long data;
}
- private LinkedList<Datapoint> trafficdata = new LinkedList<>();
+ private final LinkedList<Datapoint> trafficdata;
@Override
@@ -128,9 +128,10 @@ public class DeviceStateReceiver extends BroadcastReceiver implements ByteCountL
}
}
- public DeviceStateReceiver(OpenVPNManagement magnagement) {
+ public DeviceStateReceiver(OpenVPNManagement management) {
super();
- mManagement = magnagement;
+ trafficdata = new LinkedList<>();
+ mManagement = management;
mManagement.setPauseCallback(this);
mDisconnectHandler = new Handler();
}