Skip to content
Commit b24c5201 authored by Daekeun Kang's avatar Daekeun Kang Committed by Carles Cufí
Browse files

net: fix handle unaligned memory access in net_context_bind()



This commit addresses an issue in net_context_bind() where unaligned
memory access was not properly handled when checking for INADDR_ANY.
The problem primarily affected MCUs like ARMv6 that don't support
unaligned memory access.

- Use UNALIGNED_GET() to safely access the sin_addr.s_addr field
- Ensures correct behavior on architectures with alignment restrictions

This fix improves compatibility and prevents potential crashes or
unexpected behavior on affected platforms.

Signed-off-by: default avatarDaekeun Kang <dkkang@huconn.com>
parent 5b41ea78
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment