File tree Expand file tree Collapse file tree 2 files changed +10
-2
lines changed
android/src/main/java/com/netease/im/session Expand file tree Collapse file tree 2 files changed +10
-2
lines changed Original file line number Diff line number Diff line change @@ -160,7 +160,11 @@ public boolean updateAudioStreamType(int audioStreamType) {
160160
161161 private void changeAudioStreamType (int audioStreamType ) {
162162 if (isPlayingAudio ()) {
163- seekPosition = currentAudioPlayer .getCurrentPosition ();
163+ try {
164+ seekPosition = currentAudioPlayer .getCurrentPosition ();
165+ } catch (Exception e ) {
166+ e .printStackTrace ();
167+ }
164168 needSeek = true ;
165169 currentAudioStreamType = audioStreamType ;
166170 currentAudioPlayer .start (audioStreamType );
Original file line number Diff line number Diff line change @@ -57,7 +57,11 @@ public void handleMessage(Message var1) {
5757 switch (var1 .what ) {
5858 case 0 :
5959 if (AudioPlayerM .this .mListener != null ) {
60- AudioPlayerM .this .mListener .onPlaying ((long ) AudioPlayerM .this .mPlayer .getCurrentPosition ());
60+ try {
61+ AudioPlayerM .this .mListener .onPlaying ((long ) AudioPlayerM .this .mPlayer .getCurrentPosition ());//TODO
62+ } catch (Exception e ) {
63+ e .printStackTrace ();
64+ }
6165 }
6266
6367 this .sendEmptyMessageDelayed (0 , AudioPlayerM .this .mIntervalTime );
You can’t perform that action at this time.
0 commit comments