From 06b45adf9187c4321e2c556991d35787485887b9 Mon Sep 17 00:00:00 2001 From: sonora Date: Tue, 19 Jul 2016 16:28:19 +0200 Subject: [PATCH] test if static variables in voiceRouter alone have fixed 2 issues. --- .../src/net/osmand/plus/voice/MediaCommandPlayerImpl.java | 6 +++--- OsmAnd/src/net/osmand/plus/voice/TTSCommandPlayerImpl.java | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/OsmAnd/src/net/osmand/plus/voice/MediaCommandPlayerImpl.java b/OsmAnd/src/net/osmand/plus/voice/MediaCommandPlayerImpl.java index 1fb4fa7e09..402bb3d4ff 100644 --- a/OsmAnd/src/net/osmand/plus/voice/MediaCommandPlayerImpl.java +++ b/OsmAnd/src/net/osmand/plus/voice/MediaCommandPlayerImpl.java @@ -60,9 +60,9 @@ public class MediaCommandPlayerImpl extends AbstractPrologCommandPlayer implemen } if (mediaPlayer != null){ mediaPlayer.stop(); - //Test to see if this fixes #1351 - mediaPlayer.release(); - mediaPlayer = null; + //Nullifying here fixes #1351, but may be overkill. Let's see if static status variables in VoiceRouter do the job as well. + //mediaPlayer.release(); + //mediaPlayer = null; } if (ctx != null) { abandonAudioFocus(); diff --git a/OsmAnd/src/net/osmand/plus/voice/TTSCommandPlayerImpl.java b/OsmAnd/src/net/osmand/plus/voice/TTSCommandPlayerImpl.java index 59671f24e2..3373db03cb 100644 --- a/OsmAnd/src/net/osmand/plus/voice/TTSCommandPlayerImpl.java +++ b/OsmAnd/src/net/osmand/plus/voice/TTSCommandPlayerImpl.java @@ -133,7 +133,7 @@ public class TTSCommandPlayerImpl extends AbstractPrologCommandPlayer { ttsRequests = 0; if (mTts != null){ mTts.stop(); - //Test to see if this fixes #2810 + //Nullifying here may fix #2810, but should be overkill. Let's see if static status variables in VoiceRouter do the job as well. //mTts = null; } if (ctx != null) {