revmischa / rtsp-server

Lightweight RTSP/RTP streaming media server
https://metacpan.org/release/RTSP-Server
427 stars 111 forks source link

ffmpeg segmentation fault #11

Closed mickaelmonsieur closed 7 years ago

mickaelmonsieur commented 7 years ago

Hi,

with ffmpeg i have a segmentation fault:

root@raspberrypi:~# ffmpeg -f alsa -i default:CARD=CODEC -acodec mp3 -ab 192k -ac 2 -f rtsp rtsp://127.0.0.1:5545/live -tune zerolatency ffmpeg version N-81342-gb93e223 Copyright (c) 2000-2016 the FFmpeg developers built with gcc 4.9.2 (Raspbian 4.9.2-10) configuration: --arch=armel --target-os=linux --enable-gpl --enable-libx264 --enable-libfdk-aac --enable-libtwolame --enable-libmp3lame --enable-nonfree --extra-cflags=-I/arm/include --extra-ldflags=-L/arm/lib --extra-libs=-ldl libavutil 55. 28.100 / 55. 28.100 libavcodec 57. 51.102 / 57. 51.102 libavformat 57. 46.101 / 57. 46.101 libavdevice 57. 0.102 / 57. 0.102 libavfilter 6. 51.100 / 6. 51.100 libswscale 4. 1.100 / 4. 1.100 libswresample 2. 1.100 / 2. 1.100 libpostproc 54. 0.100 / 54. 0.100 Trailing options were found on the commandline. Guessed Channel Layout for Input Stream #0.0 : stereo Input #0, alsa, from 'default:CARD=CODEC': Duration: N/A, start: 1471425501.160857, bitrate: 1536 kb/s Stream #0:0: Audio: pcm_s16le, 48000 Hz, 2 channels, s16, 1536 kb/s [rtsp @ 0x3199ce0] Using AVStream.codec to pass codec parameters to muxers is deprecated, use AVStream.codecpar instead. Output #0, rtsp, to 'rtsp://127.0.0.1:5545/live': Metadata: encoder : Lavf57.46.101 Stream #0:0: Audio: mp3 (libmp3lame), 48000 Hz, stereo, s16p, 192 kb/s Metadata: encoder : Lavc57.51.102 libmp3lame Stream mapping: Stream #0:0 -> #0:0 (pcm_s16le (native) -> mp3 (libmp3lame)) Press [q] to stop, [?] for help Segmentation fault root@raspberrypi:~#

log from rtsp-server:

root@raspberrypi:/usr/src# /usr/src/rtsp-server/rtsp-server.pl --loglevel 10 Starting RTSP server, log level = 10 Source server started Client server started Source connection from 127.0.0.1:39314 Source listener: >> OPTIONS rtsp://127.0.0.1:5545/live RTSP/1.0 Got method OPTIONS Source listener: >> CSeq: 1 Source listener: >> User-Agent: Lavf57.46.101 Source listener: >> End of headers << RTSP/1.0 200 OK << Public: OPTIONS, DESCRIBE, TEARDOWN, SETUP, ANNOUNCE, RECORD << CSeq: 1 << Session: 1 Source listener: >> ANNOUNCE rtsp://127.0.0.1:5545/live RTSP/1.0 Got method ANNOUNCE Source listener: >> Content-Type: application/sdp Source listener: >> CSeq: 2 Source listener: >> User-Agent: Lavf57.46.101 Source listener: >> Session: 1 Source listener: >> Content-Length: 153 Source listener: >> End of headers Finished reading body, length=153 Got source announcement for rtsp://127.0.0.1:5545/live Mounted /live << RTSP/1.0 200 OK << CSeq: 2 << Session: 1 Source listener: >> SETUP rtsp://127.0.0.1:5545/live/streamid=0 RTSP/1.0 Got method SETUP Source listener: >> Transport: RTP/AVP/UDP;unicast;client_port=18972-18973;mode=record Source listener: >> CSeq: 3 Source listener: >> User-Agent: Lavf57.46.101 Source listener: >> Session: 1 Source listener: >> End of headers Got SETUP request for stream 0 Creating new stream 0 << RTSP/1.0 200 OK << Transport: RTP/AVP/UDP;unicast;client_port=18972-18973;mode=record;server_port=20000-20001 << CSeq: 3 << Session: 1 Source listener: >> RECORD rtsp://127.0.0.1:5545/live RTSP/1.0 Got method RECORD Source listener: >> Range: npt=0.000- Source listener: >> CSeq: 4 Source listener: >> User-Agent: Lavf57.46.101 Source listener: >> Session: 1 Source listener: >> End of headers Got record for mountpoint /live Starting RTP listeners |-- stream 0 |---- port 20000 |---- port 20001 << RTSP/1.0 200 OK << CSeq: 4 << Session: 1 Got EOF on listener

do you have an idea?

revmischa commented 7 years ago

Interesting, I’m afraid that looks more like a ffmpeg issue. They may be able to help you on their mailing list or on Freenode. You may want to run under gdb and get a backtrace, or find the corefile. "Segmentation fault" isn't much to go on

LeRatierBretonnien commented 7 years ago

This is a FFMPEG bug, fixed in the git head of ffmpeg (see https://trac.ffmpeg.org/ticket/5844 )