Yalir / sfeMovie

sfeMovie is a simple C++ library that lets you play movies in SFML based applications. It relies on FFmpeg to read medias and remains consistent with SFML's naming conventions.
http://sfemovie.yalir.org/
GNU Lesser General Public License v2.1
114 stars 37 forks source link

Crashes after movie ends #44

Closed krofna closed 11 years ago

krofna commented 11 years ago
[New Thread 0x7fffeb523700 (LWP 27533)]
[Thread 0x7fffeb523700 (LWP 27533) exited]
[New Thread 0x7fffeb523700 (LWP 27534)]
[New Thread 0x7fffe6d21700 (LWP 27535)]
[mpeg @ 0xb0efe0] max_analyze_duration 5000000 reached at 5005000
[New Thread 0x7fffe6520700 (LWP 27536)]
[New Thread 0x7fffe5d1f700 (LWP 27537)]
[New Thread 0x7fffe551e700 (LWP 27538)]
[New Thread 0x7fffe4d1d700 (LWP 27539)]
[New Thread 0x7fffdffff700 (LWP 27540)]
[New Thread 0x7fffdf5be700 (LWP 27541)]
[New Thread 0x7fffdedbd700 (LWP 27542)]
[New Thread 0x7fffde5bc700 (LWP 27543)]
[Thread 0x7fffdedbd700 (LWP 27542) exited]
[Thread 0x7fffde5bc700 (LWP 27543) exited]
[New Thread 0x7fffde5bc700 (LWP 28358)]
[New Thread 0x7fffdedbd700 (LWP 28359)]
[New Thread 0x7fffddcbb700 (LWP 28360)]

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 0x7fffde5bc700 (LWP 28358)]
av_packet_get_side_data (pkt=0x0, type=type@entry=AV_PKT_DATA_SKIP_SAMPLES, size=size@entry=0x7fffde5bb9ec)
    at /tmp/ffmpeg/libavcodec/avpacket.c:216
216 /tmp/ffmpeg/libavcodec/avpacket.c: No such file or directory.
(gdb) bt
#0  av_packet_get_side_data (pkt=0x0, type=type@entry=AV_PKT_DATA_SKIP_SAMPLES, size=size@entry=0x7fffde5bb9ec)
    at /tmp/ffmpeg/libavcodec/avpacket.c:216
#1  0x00007ffff45a8ab7 in avcodec_decode_audio4 (avctx=avctx@entry=0xb49f00, frame=frame@entry=0x7fffde5bbab0, 
    got_frame_ptr=got_frame_ptr@entry=0x7fffde5bbaa8, avpkt=0x7fffd4832200) at /tmp/ffmpeg/libavcodec/utils.c:1700
#2  0x00007ffff45a8eea in avcodec_decode_audio3 (avctx=0xb49f00, samples=0xf56f80, frame_size_ptr=0x7fffde5bbd0c, avpkt=<optimized out>)
    at /tmp/ffmpeg/libavcodec/utils.c:1623
#3  0x00007ffff70d5096 in sfe::Movie_audio::decodeFrontFrame(sf::SoundStream::Chunk&) () from /usr/local/lib/libsfeMovie.so.1.1.0
#4  0x00007ffff70d52a0 in sfe::Movie_audio::onGetData(sf::SoundStream::Chunk&) () from /usr/local/lib/libsfeMovie.so.1.1.0
#5  0x00007ffff4fd107d in sf::SoundStream::fillAndPushBuffer(unsigned int) () from /usr/lib/x86_64-linux-gnu/libsfml-audio.so.2
#6  0x00007ffff4fd1181 in sf::SoundStream::fillQueue() () from /usr/lib/x86_64-linux-gnu/libsfml-audio.so.2
#7  0x00007ffff4fd123d in sf::SoundStream::streamData() () from /usr/lib/x86_64-linux-gnu/libsfml-audio.so.2
#8  0x00007ffff7527488 in ?? () from /usr/lib/x86_64-linux-gnu/libsfml-system.so.2
#9  0x00007ffff53e5e0e in start_thread (arg=0x7fffde5bc700) at pthread_create.c:311
#10 0x00007ffff65f09ed in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:113

OS: Debian unstable/experimental sfeMovie: edb7a6eff8edf38364d8db739d6ccc7775ae0f8d SFML: libsfml-dev 2.1 (from experimental) Code which reproduces this crash: https://github.com/Future-Gadget-Research-Establishment/libnpengine/blob/master/src/game.cpp

krofna commented 11 years ago

Oops, looks like its my fault; I figured it out; sorry :/