From 1ac1b6e68f40f0a7e1e6b8497d32e2970ef51bdf Mon Sep 17 00:00:00 2001 From: Gregory Nutt Date: Wed, 3 May 2017 08:04:20 -0600 Subject: [PATCH] MAC: meta data must be const to assure that it is not modified. --- wireless/ieee802154/mac802154.c | 4 ++-- wireless/ieee802154/mac802154.h | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/wireless/ieee802154/mac802154.c b/wireless/ieee802154/mac802154.c index 39bdb2ec2a..491641da99 100644 --- a/wireless/ieee802154/mac802154.c +++ b/wireless/ieee802154/mac802154.c @@ -844,7 +844,7 @@ int mac802154_ioctl(MACHANDLE mac, int cmd, unsigned long arg) ****************************************************************************/ int mac802154_get_mhrlen(MACHANDLE mac, - FAR struct ieee802154_frame_meta_s *meta) + FAR const struct ieee802154_frame_meta_s *meta) { FAR struct ieee802154_privmac_s *priv = (FAR struct ieee802154_privmac_s *)mac; @@ -927,7 +927,7 @@ int mac802154_req_data(MACHANDLE mac, FAR struct ieee802154_data_req_s *req) FAR struct ieee802154_privmac_s *priv = (FAR struct ieee802154_privmac_s *)mac; FAR struct mac802154_trans_s trans; - FAR struct ieee802154_frame_meta_s *meta = req->meta; + FAR const struct ieee802154_frame_meta_s *meta = req->meta; uint16_t *frame_ctrl; uint8_t mhr_len = 3; /* Start assuming frame control and seq. num */ int ret; diff --git a/wireless/ieee802154/mac802154.h b/wireless/ieee802154/mac802154.h index d0d7e82ce2..8042b84c33 100644 --- a/wireless/ieee802154/mac802154.h +++ b/wireless/ieee802154/mac802154.h @@ -106,7 +106,7 @@ int mac802154_ioctl(MACHANDLE mac, int cmd, unsigned long arg); ****************************************************************************/ int mac802154_get_mhrlen(MACHANDLE mac, - FAR struct ieee802154_frame_meta_s *meta); + FAR const struct ieee802154_frame_meta_s *meta); /**************************************************************************** * Name: mac802154_req_data