pespin submitted this change.

View Change

Approvals: fixeria: Looks good to me, approved Jenkins Builder: Verified osmith: Looks good to me, but someone else must approve
csn1.h: Fix missing include stddef.h for offsetof()

Fixes following compiler error:
"""
In file included from /osmo-pcu/src/gsm_rlcmac.c:32:
/osmo-pcu/src/csn1.h:310:32: error: implicit declaration of function 'offsetof' [-Wimplicit-function-declaration]
310 | {CSN_UINT, _BITS, {0}, offsetof(_STRUCT, _MEMBER), FALSE, #_MEMBER, 0, NULL}
| ^~~~~~~~
/osmo-pcu/src/gsm_rlcmac.c:43:3: note: in expansion of macro 'M_UINT'
43 | M_UINT (PLMN_t, MCC2, 4),
| ^~~~~~
/osmo-pcu/src/gsm_rlcmac.c:38:1: note: 'offsetof' is defined in header '<stddef.h>'; this is probably fixable by adding '#include <stddef.h>'
37 | #include <gprs_debug.h>
+++ |+#include <stddef.h>
"""

Change-Id: I3ddd10dd67e7850ace36ac996598cbfd4bbaa40e
---
M src/csn1.h
1 file changed, 2 insertions(+), 0 deletions(-)

diff --git a/src/csn1.h b/src/csn1.h
index 6607b02..66e67ba 100644
--- a/src/csn1.h
+++ b/src/csn1.h
@@ -24,6 +24,8 @@
#ifndef _PACKET_CSN1_H_
#define _PACKET_CSN1_H_

+#include <stddef.h>
+
#include <osmocom/core/bitvec.h>
#include "wireshark_compat.h"


To view, visit change 41886. To unsubscribe, or for help writing mail filters, visit settings.

Gerrit-MessageType: merged
Gerrit-Project: osmo-pcu
Gerrit-Branch: master
Gerrit-Change-Id: I3ddd10dd67e7850ace36ac996598cbfd4bbaa40e
Gerrit-Change-Number: 41886
Gerrit-PatchSet: 1
Gerrit-Owner: pespin <pespin@sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy@sysmocom.de>
Gerrit-Reviewer: osmith <osmith@sysmocom.de>
Gerrit-Reviewer: pespin <pespin@sysmocom.de>