libosmocore/src/gb
Harald Welte 2033be8902 Work around bogus gcc-8.2 array-bounds warning/error
gcc-8.2 is printing the following warning, which is an error
when used -Werror like our --enable-werror:

In file included from gprs_bssgp.c:34:
In function ‘tl16v_put’,
    inlined from ‘tvlv_put.part.3’ at ../../include/osmocom/gsm/tlv.h:156:9,
    inlined from ‘tvlv_put’ at ../../include/osmocom/gsm/tlv.h:147:24,
    inlined from ‘msgb_tvlv_push’ at ../../include/osmocom/gsm/tlv.h:386:2,
    inlined from ‘bssgp_tx_dl_ud’ at gprs_bssgp.c:1162:4:
../../include/osmocom/gsm/tlv.h:131:2: error: ‘memcpy’ forming offset [12, 130] is out of the bounds [0, 11] of object ‘mi’ with type ‘uint8_t[11]’ {aka ‘unsigned char[11]’} [-Werror=array-bounds]
  memcpy(buf, val, len);

Where "130" seems to be the maximum value of uint8_t, shifted right one +
2.  But even as we use strnlen() with "16" as maximum upper bound, gcc
still believes there's a way that the return value of gsm48_generate_mid_from_imsi()
could be 130.  In fact, even the newly-added OSMO_ASSERT() inside
gsm48_generate_mid() doesn't help and gcc still insists there is a problem :(

Change-Id: I0a06daa19b7b5b5badbb8b3d81a54c45b88a60ec
2019-01-22 14:53:54 +00:00
..
Makefile.am Bump version: 0.12.0.128-8dfde → 1.0.0 2019-01-19 22:07:56 +01:00
common_vty.c Fix/Update copyright notices; Add SPDX annotation 2017-11-13 01:35:12 +09:00
common_vty.h gb: drop special vty exit commands, use vty_install_default() 2017-09-27 14:04:08 +00:00
gprs_bssgp.c Work around bogus gcc-8.2 array-bounds warning/error 2019-01-22 14:53:54 +00:00
gprs_bssgp_bss.c Work around bogus gcc-8.2 array-bounds warning/error 2019-01-22 14:53:54 +00:00
gprs_bssgp_util.c Fix/Update copyright notices; Add SPDX annotation 2017-11-13 01:35:12 +09:00
gprs_bssgp_vty.c implement support for 3-digit MNC with leading zeros 2018-02-28 19:26:33 +01:00
gprs_ns.c document unblock-ack vs. signalling in gprs_ns_process_msg() 2018-11-20 11:06:05 +01:00
gprs_ns_frgre.c Fix/Update copyright notices; Add SPDX annotation 2017-11-13 01:35:12 +09:00
gprs_ns_vty.c Fix/Update copyright notices; Add SPDX annotation 2017-11-13 01:35:12 +09:00
libosmogb.map bssgp: introduce flush queue functions 2018-08-10 06:55:43 +00:00