MAC: meta data must be const to assure that it is not modified.

This commit is contained in:
Gregory Nutt 2017-05-03 08:04:20 -06:00
parent 0afae22638
commit 1ac1b6e68f
2 changed files with 3 additions and 3 deletions

View File

@ -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;

View File

@ -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