Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

Empty channel in mixed recorded file if option "output-mixed-per-media" is true

Open
#1,892 2 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 2 days

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
22/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Stale
Tech stack
c

Research direction

The report localises the fault in rtpengine-recording's mix_add(), at the check if (ptr != mix->input_ref[idx]) that raises "received samples for old re-used input channel". Start by reading that function and how input_ref slots are assigned when output-mixed-per-media is set, comparing the per-media path against output-mixed-per-media=false. The attached rtpengine and rtpengine-recording logs plus the metafile show the session; done means a stereo mix where both channels carry their stream's audio.

Written by the indexing model from the issue text.

Description

bug
rtpengine version the issue has been seen with

git-HEAD-5e14aac1

Used distribution and its version

Red Hat Enterprise Linux 8.10

Linux kernel version used

4.18.0-553.32.1.el8_10.x86_64

CPU architecture issue was seen on (see uname -m)

x86_64

Expected behaviour you didn't see

We have simple siprec call with 2 media streams, no SSRC switching
Mixing-related options of rtpengine-recording:
output-mixed = true
output-single = true
mix-method = channels
output-mixed-per-media = true
mix-num-inputs = 2
We expect to see 2 mono recorded files (one file per media stream) and stereo mixed recorded file where each channel contains audio from corresponding media stream. Generally speaking, we expect the same result as with output-mixed-per-media = false.

Unexpected behaviour you saw

Mono files are OK, in stereo file only one channel has audio from one stream, second channel is empty.

Steps to reproduce the problem

Session with rtpengine created via commands offer/answer (piece of rtpengine log with command content attached), recording started via command "start" (piece of rtpengine log with command content attached).
Attached:

  1. Metafile, created by rtpengine
  2. Piece of rtpengine log with processing of commands "offer", "answer" and "start recording"
  3. Piece of rtpengine-recording log with processing of session for call ID [email protected]

Btw, from rtpengine-recording log is clear that in case of packet from stream with SSRC 0x50a545bf function mix_add() always go to errror exit here
err = "received samples for old re-used input channel";
if (ptr != mix->input_ref[idx])
goto err;
what causes corresponding error log output.

Additional program output to the terminal or logs illustrating the issue

No response

Anything else?

Attached files:
rtpengine_files.zip

Dominant language
Perl
Stars
992
Forks
459
PR merge metrics
No merged PRs in 30d

Getting set up

This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from sipwise/rtpengine

All issues in sipwise/rtpengine

Similar issues

More Perl issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.