diff options
author | Vadim Yanitskiy <axilirator@gmail.com> | 2019-05-03 00:37:31 +0200 |
---|---|---|
committer | Vadim Yanitskiy <axilirator@gmail.com> | 2019-05-03 00:48:35 +0200 |
commit | 04a46d091bb6367f961d184e5f103a95253ce4f1 (patch) | |
tree | 1cb96724c1e272ab6373b4c73592617f19a0503d | |
parent | e8c179a5755b2429fcaeb43430672f1587d56931 (diff) |
mobile/gsm48_rr.h: mark gsm48_rr_hdr struct as packed
In both gsm48_mm.c and gsm48_rr.c we put / push 'gsm48_rr_hdr'
structure into the message buffers, so then it's retrieved by
the message receivers. The AddressSanitizer complains about
unaligned pointer access and potentially unexpected behaviour.
Change-Id: I8aa2c0074b405afd0e76044ef076b6819fe1083b
-rw-r--r-- | src/host/layer23/include/osmocom/bb/mobile/gsm48_rr.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/host/layer23/include/osmocom/bb/mobile/gsm48_rr.h b/src/host/layer23/include/osmocom/bb/mobile/gsm48_rr.h index 6235bfdb..6996ff35 100644 --- a/src/host/layer23/include/osmocom/bb/mobile/gsm48_rr.h +++ b/src/host/layer23/include/osmocom/bb/mobile/gsm48_rr.h @@ -61,7 +61,7 @@ struct gsm48_rr_hdr { uint32_t msg_type; /* RR-* primitive */ uint8_t sapi; uint8_t cause; -}; +} __attribute__((packed)); /* GSM 04.07 9.1.1 */ #define GSM48_RR_ST_IDLE 0 |