Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SEGV in vconv.c for video call with RX thread #1256

Closed
cspiel1 opened this issue Jan 8, 2025 · 5 comments · Fixed by #1257
Closed

SEGV in vconv.c for video call with RX thread #1256

cspiel1 opened this issue Jan 8, 2025 · 5 comments · Fixed by #1257
Labels
bug Something isn't working

Comments

@cspiel1
Copy link
Collaborator

cspiel1 commented Jan 8, 2025

  • configure rtp_rxmode thread
  • Initiate a call with video

As soon as the video thread starts baresip crashes.

#0  yuyv422_to_yuv420p
    (xsoffs=0, xdoffs=0, width=640, rw=1, yd=0, ys=3019894192, ys2=3019894193, dd0=0x7fffc85ca110 "", dd1=0x7fffc8615110 "", dd2=0x7fffc8627d10 "", lsd=640, sd0=0x7fffc87fd000 "\255z\254\202\255y\255\177\255|\254\200\253{\254\177\254|\255|\251}\255}\252{\252~\254|\254\177\251\177\251}\253\177\253\200\251\177\253\201\254\177\247\200\245}\250\177\246}\245\177\243}\243\177\245}\244\200\243}\244\201\243|\241\201\243\177\241\201\237~\235\200\235~\236{\240~\234}\227~\222{\220\200\220\177\220\203\223\201\222\202\222\202\220~\215\177\220{\215~\220|\216y\220\200\217|\214\200\214\177\210\200\210~\206~\206y\204\177\202z\205\177\205\201\204}\202\201\202}}~n~r\200t~w\201z}z\205|}s\202\202x\242\212\246r\252\211\252r\251\206\250x\251\211\251u\246\217\247r\247\215\251q\253\214\252q\253\211\247s\252\211"..., sd1=0x0, sd2=0x0, lss=1280) at /home/cspiel/src/re/rem/vidconv/vconv.c:246
#1  0x00007ffff7f2a8cd in vidconv (dst=0x7fffc85ca0d0, src=0x7fffb3ffed10, r=0x7fffb3ffec20) at /home/cspiel/src/re/rem/vidconv/vconv.c:783
#2  0x00007ffff7fa0065 in encode_rtp_send (vtx=0x5555556f7a08, frame=0x7fffb3ffed10, packet=0x0, timestamp=4666272399)
    at /home/cspiel/src/baresip/src/video.c:435
#3  0x00007ffff7fa0257 in vidsrc_frame_handler (frame=0x7fffb3ffed10, timestamp=4666272399, arg=0x5555556f7a08) at /home/cspiel/src/baresip/src/video.c:488
#4  0x00007ffff44c7eaf in call_frame_handler
    (st=0x55555575bfc0, buf=0x7fffc87fd000 "\255z\254\202\255y\255\177\255|\254\200\253{\254\177\254|\255|\251}\255}\252{\252~\254|\254\177\251\177\251}\253\177\253\200\251\177\253\201\254\177\247\200\245}\250\177\246}\245\177\243}\243\177\245}\244\200\243}\244\201\243|\241\201\243\177\241\201\237~\235\200\235~\236{\240~\234}\227~\222{\220\200\220\177\220\203\223\201\222\202\222\202\220~\215\177\220{\215~\220|\216y\220\200\217|\214\200\214\177\210\200\210~\206~\206y\204\177\202z\205\177\205\201\204}\202\201\202}}~n~r\200t~w\201z}z\205|}s\202\202x\242\212\246r\252\211\252r\251\206\250x\251\211\251u\246\217\247r\247\215\251q\253\214\252q\253\211\247s\252\211"..., timestamp=4666272399) at /home/cspiel/src/baresip/modules/v4l2/v4l2.c:359
#5  0x00007ffff44c800d in read_frame (st=0x55555575bfc0) at /home/cspiel/src/baresip/modules/v4l2/v4l2.c:399
#6  0x00007ffff44c82a6 in read_thread (arg=0x55555575bfc0) at /home/cspiel/src/baresip/modules/v4l2/v4l2.c:472
#7  0x00007ffff7ee0a23 in handler (p=0x55555574f180) at /home/cspiel/src/re/src/thread/thread.c:105
#8  0x00007ffff7f1f0a6 in handler (p=0x5555556fe450) at /home/cspiel/src/re/src/thread/posix.c:21
#9  0x00007ffff75b439d in start_thread (arg=<optimized out>) at pthread_create.c:447
#10 0x00007ffff763949c in __GI___clone3 () at ../sysdeps/unix/sysv/linux/x86_64/clone3.S:78
@cspiel1 cspiel1 added the bug Something isn't working label Jan 8, 2025
@cspiel1 cspiel1 changed the title SEGV in vconv.c with outgoing early video SEGV in vconv.c for video call with rtp_rxmode thread Jan 8, 2025
@cspiel1 cspiel1 changed the title SEGV in vconv.c for video call with rtp_rxmode thread SEGV in vconv.c for video call with RX thread Jan 8, 2025
@cspiel1
Copy link
Collaborator Author

cspiel1 commented Jan 8, 2025

frame #0
(gdb) p id
$1 = 0
(gdb) p is
$2 = 257191936

@cspiel1
Copy link
Collaborator Author

cspiel1 commented Jan 8, 2025

@sreimers Maybe this was introduced with #1240 ?

@sreimers
Copy link
Member

sreimers commented Jan 8, 2025

Can you try: baresip/baresip#3266

@sreimers
Copy link
Member

sreimers commented Jan 8, 2025

A better fix: #1257

@cspiel1
Copy link
Collaborator Author

cspiel1 commented Jan 8, 2025

A better fix: #1257

Indeed. This solves the SEGV.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants