diff --git a/include/bluetooth/buf.h b/include/bluetooth/buf.h index d02cf69914cd3..11113ee903aaf 100644 --- a/include/bluetooth/buf.h +++ b/include/bluetooth/buf.h @@ -82,7 +82,7 @@ static inline void bt_buf_set_type(struct net_buf *buf, enum bt_buf_type type) */ static inline enum bt_buf_type bt_buf_get_type(struct net_buf *buf) { - return *(u8_t *)net_buf_user_data(buf); + return *((enum bt_buf_type *)net_buf_user_data(buf)); } /** diff --git a/include/bluetooth/gatt.h b/include/bluetooth/gatt.h index 62fc49617b5fc..55fb59b779e3b 100644 --- a/include/bluetooth/gatt.h +++ b/include/bluetooth/gatt.h @@ -895,7 +895,7 @@ struct bt_gatt_read_params { bt_gatt_read_func_t func; size_t handle_count; union { - struct __single { + struct { u16_t handle; u16_t offset; } single;