Fixed another NPE.
This commit is contained in:
parent
6e5408848f
commit
6b89fded4f
1 changed files with 10 additions and 4 deletions
|
|
@ -832,10 +832,16 @@ public class MusicService extends Service implements SharedPreferences.OnSharedP
|
|||
}
|
||||
|
||||
public int seek(int millis) {
|
||||
int newPosition = playback.seek(millis);
|
||||
savePositionInTrack();
|
||||
throttledPublicPlayStateChangedNotifier.scheduleIntent();
|
||||
return newPosition;
|
||||
synchronized (this) {
|
||||
try {
|
||||
int newPosition = playback.seek(millis);
|
||||
savePositionInTrack();
|
||||
throttledPublicPlayStateChangedNotifier.scheduleIntent();
|
||||
return newPosition;
|
||||
} catch (Exception e) {
|
||||
return -1;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void cycleRepeatMode() {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue