Skip to content
Commit f86e8a66 authored by Carles Cufi's avatar Carles Cufi Committed by Anas Nashif
Browse files

random: rand32_timer: Avoid alignment faults by using memcpy



The previous implementation assumed that the dst pointer was always
aligned to a 4-byte boundary in platforms that require alignment for
storage of 32-bit integers. Since this is required for certain platforms
(eg. Arm Cortex-M0), use memcpy() instead, which always takes
alignment into account.

Fixes #33969.

Signed-off-by: default avatarCarles Cufi <carles.cufi@nordicsemi.no>
parent 286d9c22
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment