[PATCH] gsm0480.c: squelch compiler warning due to const (caused recently)

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/.

Harald Welte laforge at gnumonks.org
Wed Mar 16 10:28:30 UTC 2016


Hi Neels,

On Mon, Mar 14, 2016 at 11:52:39PM +0100, Neels Hofmeyr wrote:
> The introduction of gsm48_hdr_pdisc() caused a new compiler warning.
> In gsm0480_decode_*(), the gsm48_hdr is const, which we can safely cast
> away to avoid the warning.

Why does gsm48_hdr_pdisc() not take a 'const struct gsm48_hdr *'
argument in the first place?  I don't think it modifies the contents of
the structure...


-- 
- Harald Welte <laforge at gnumonks.org>           http://laforge.gnumonks.org/
============================================================================
"Privacy in residential applications is a desirable marketing option."
                                                  (ETSI EN 300 175-7 Ch. A6)



More information about the OpenBSC mailing list