From 667af697678e70844d80555944e7cc3b5478c334 Mon Sep 17 00:00:00 2001 From: Zahnstocher Date: Tue, 2 Dec 2014 21:48:41 +0100 Subject: [PATCH] Fix null pointer --- OsmAnd/src/net/osmand/plus/routing/VoiceRouter.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/OsmAnd/src/net/osmand/plus/routing/VoiceRouter.java b/OsmAnd/src/net/osmand/plus/routing/VoiceRouter.java index 0271fd28e1..fd6f05b5b0 100644 --- a/OsmAnd/src/net/osmand/plus/routing/VoiceRouter.java +++ b/OsmAnd/src/net/osmand/plus/routing/VoiceRouter.java @@ -77,7 +77,7 @@ public class VoiceRouter { public interface VoiceMessageListener { void onVoiceMessage(); } - private ConcurrentHashMap voiceMessageListeners; + private ConcurrentHashMap voiceMessageListeners; public VoiceRouter(RoutingHelper router, final OsmandSettings settings, CommandPlayer player) { this.router = router; @@ -85,7 +85,7 @@ public class VoiceRouter { this.settings = settings; empty = new Struct(""); - voiceMessageListeners = new ConcurrentHashMap(); + voiceMessageListeners = new ConcurrentHashMap(); } public void setPlayer(CommandPlayer player) { @@ -842,7 +842,7 @@ public class VoiceRouter { } public void addVoiceMessageListener(VoiceMessageListener voiceMessageListener) { - voiceMessageListeners.put(voiceMessageListener, null); + voiceMessageListeners.put(voiceMessageListener, 0); } public void removeVoiceMessageListener(VoiceMessageListener voiceMessageListener) {