Opened 11 years ago

Closed 11 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 by EricV, 11 years ago

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 by Elon Musk, 11 years ago

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

in reply to:  2 ; comment:3 by marillat, 11 years ago

Replying to richardpl:

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

ffmpeg must not crash other programs.

in reply to:  3 ; comment:4 by Carl Eugen Hoyos, 11 years ago

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?

in reply to:  4 comment:5 by marillat, 11 years ago

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

in reply to:  4 ; comment:6 by marillat, 11 years ago

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 by Elon Musk, 11 years ago

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

in reply to:  6 comment:8 by Michael Niedermayer, 11 years ago

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 by marillat, 11 years ago

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

in reply to:  9 ; comment:10 by Michael Niedermayer, 11 years ago

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

in reply to:  10 comment:11 by marillat, 11 years ago

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 by Elon Musk, 11 years ago

Resolution: invalid
Status: newclosed
Note: See TracTickets for help on using tickets.