Skip to content

Commit 67b1fb3

Browse files
authored
fix: wavegen closing crash (#2272)
1 parent 88826a7 commit 67b1fb3

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

app/src/main/java/io/pslab/activity/WaveGeneratorActivity.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1370,7 +1370,8 @@ protected void onCancelled() {
13701370
@Override
13711371
public void onBackPressed() {
13721372
super.onBackPressed();
1373-
produceSoundTask.cancel(true);
1373+
if(produceSoundTask != null)
1374+
produceSoundTask.cancel(true);
13741375
produceSoundTask = null;
13751376
isPlayingSound = false;
13761377
}

0 commit comments

Comments
 (0)