This is merely a historical archive of years 2008-2021, before the migration to mailman3.
A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/OpenBSC@lists.osmocom.org/.
Holger Hans Peter Freyther holger at freyther.deOn Mon, May 12, 2014 at 12:39:01PM +0200, Jacob Erlbeck wrote:
> +#include "g711common.h"
> +#include <gsm.h>
> +#include <bcg729/decoder.h>
> +#include <bcg729/encoder.h>
these must be guarded with the approriate defines. Specially the g729
ones. I think you are lucky as /usr/include/bcg729/encoder.h just
exists. :)
> +++ b/openbsc/src/osmo-bsc_mgcp/mgcp_transcode.c
> @@ -0,0 +1,459 @@
> +/*
> + * (C) 2014 by On-Waves
shared copyright here. :)
> +#include "../../bscconfig.h"
Does this work with make distcheck? srcdir != builddir?
> + /* cleanup first */
> + if (state) {
> + talloc_free(state);
> + dst_end->rtp_process_data = NULL;
state = NULL;
> + }
Or just avoid assigning state that early?
> + LOGP(DMGCP, LOGL_ERROR,
> + "Cannot transcode: %s codec not supported (%s -> %s).\n",
> + src_fmt != AF_INVALID ? "destination" : "source",
> + src_end->audio_name, dst_end->audio_name);
> + return -EINVAL;
Will the CRCX/MDCX fail in this case? I am a bit too lazy to check this
right now.
> + /* TODO: remove me
> + fprintf(stderr, "sample_cnt = %d, sample_idx = %d, plen = %d -> %d, "
> + "hdr_size = %d, len = %d, pt = %d\n",
> + sample_cnt, sample_idx, payload_len, nbytes, rtp_hdr_size, *len,
> + data[1]);
> + */
You want to keep this for now?
> +#ifndef OPENBSC_MGCP_TRANSCODE_H
> +#define OPENBSC_MGCP_TRANSCODE_H
I started to use "#pragma once". It is supported by GCC for a long
time and even the Microsoft Compiler handles it correctly.