Opened 7 years ago

Closed 6 years ago

#2134 closed defect (invalid)

libavcodec and AC3 audio crash XBMC

Reported by: marillat Owned by:
Priority: normal Component: undetermined
Version: 1.1 Keywords:
Cc: Blocked By:
Blocking: Reproduced by developer: no
Analyzed by developer: no

Description

Hi,

Since 1.1 XBMC crash with an Arithmetic exception when reading a video with an AC3 audio track and only AC3 track.

I did a bug report for XBMC, but I think the problem is in libavcodec as 1.0.1 don't crash XBMC. A XBMC rebuild against 1.1 changes nothing.

http://trac.xbmc.org/ticket/13944

Program received signal SIGFPE, Arithmetic exception.
[Switching to Thread 0xa81cfb70 (LWP 19280)]
0x0876d47d in GetDelay (this=0xa905fea8) at Engines/SoftAE/SoftAEStream.cpp:486
486	  delay += (double)(m_inputBuffer.Used() / m_format.m_frameSize) / (double)m_format.m_sampleRate;
(gdb) bt
#0  0x0876d47d in GetDelay (this=0xa905fea8) at Engines/SoftAE/SoftAEStream.cpp:486
#1  CSoftAEStream::GetDelay (this=0xa905fea8) at Engines/SoftAE/SoftAEStream.cpp:480
#2  0x0864d79d in CDVDAudio::GetDelay (this=<error reading variable: Cannot access memory at address 0xa81cf100>, this@entry=<error reading variable: Cannot access memory at address 0xa81cf0fc>) at DVDAudio.cpp:363
(gdb) quit

Change History (12)

comment:1 Changed 7 years ago by EricV

I can confirm the problem but with a different stack frame on amd64 : I get an assert in XBMC. Same XBMC code compiled with 1.0.1 works, reverting to 1.0.1 and rebuilding XBMC makes it work again.

Same symptom EAC3 5.1 audio, whaever means to get it (file, UPnP, PVR, ..).

comment:2 follow-up: Changed 7 years ago by richardpl

If it can not be reproduced with ffmpeg it is not ffmpeg bug.

comment:3 in reply to: ↑ 2 ; follow-up: Changed 7 years ago by marillat

Replying to richardpl:

If it can not be reproduced with ffmpeg it is not ffmpeg bug.

ffmpeg must not crash other programs.

comment:4 in reply to: ↑ 3 ; follow-ups: Changed 7 years ago by cehoyos

Replying to marillat:

Replying to richardpl:

If it can not be reproduced with ffmpeg it is not ffmpeg bug.

ffmpeg must not crash other programs.

I completely agree but the backtrace you provided does not indicate a crash in libavcodec...

Is the XBMC source code aware that libavcodec now outputs AV_SAMPLE_FMT_FLTP for ac3?

comment:5 in reply to: ↑ 4 Changed 7 years ago by marillat

Replying to cehoyos:

Replying to marillat:

Replying to richardpl:

If it can not be reproduced with ffmpeg it is not ffmpeg bug.

ffmpeg must not crash other programs.

I completely agree but the backtrace you provided does not indicate a crash in libavcodec...

Is the XBMC source code aware that libavcodec now outputs AV_SAMPLE_FMT_FLTP for ac3?

As me no. Would be nice to document this sort of change somewhere, users/coders can't quess that.

You can close this "bug".

Christian

comment:6 in reply to: ↑ 4 ; follow-up: Changed 7 years ago by marillat

Replying to cehoyos:

Replying to marillat:

Replying to richardpl:

If it can not be reproduced with ffmpeg it is not ffmpeg bug.

ffmpeg must not crash other programs.

I completely agree but the backtrace you provided does not indicate a crash in libavcodec...

Is the XBMC source code aware that libavcodec now outputs AV_SAMPLE_FMT_FLTP for ac3?

Just a quick note. As you are breaking the binary compatibility a libavcodec soname change should be done.
This sort of change is really annoying as XBMC (and probably others applications) stop to works.

comment:7 Changed 7 years ago by richardpl

We did not do it, it was done by Libav folks.

comment:8 in reply to: ↑ 6 Changed 7 years ago by michael

Replying to marillat:

Replying to cehoyos:

Replying to marillat:

Replying to richardpl:

If it can not be reproduced with ffmpeg it is not ffmpeg bug.

ffmpeg must not crash other programs.

I completely agree but the backtrace you provided does not indicate a crash in libavcodec...

Is the XBMC source code aware that libavcodec now outputs AV_SAMPLE_FMT_FLTP for ac3?

Just a quick note. As you are breaking the binary compatibility a libavcodec soname change should be done.
This sort of change is really annoying as XBMC (and probably others applications) stop to works.

The format is indicated in AVCodecContext.sample_fmt and AVFrame.format, applications should check/use their value.

comment:9 follow-up: Changed 7 years ago by marillat

Another issue, sound is now broken in vlc with wmv files.

comment:10 in reply to: ↑ 9 ; follow-up: Changed 7 years ago by michael

Replying to marillat:

Another issue, sound is now broken in vlc with wmv files.

Is that with vlc git master or something older ?
Also maybe better if this is moved to a seperate ticket

comment:11 in reply to: ↑ 10 Changed 7 years ago by marillat

Replying to michael:

Replying to marillat:

Another issue, sound is now broken in vlc with wmv files.

Is that with vlc git master or something older ?

The current stable version 2.0.5

Also maybe better if this is moved to a seperate ticket

For now I moved back to ffmpeg 1.0.1

comment:12 Changed 6 years ago by richardpl

  • Resolution set to invalid
  • Status changed from new to closed
Note: See TracTickets for help on using tickets.