Skip to content
Commit e6f179d1 authored by Tim Pambor's avatar Tim Pambor Committed by Dan Kalowsky
Browse files

tests: net: dns-sd: Fix undefined behavior reported by UBSAN



htons() takes uint16_t as argument. Add the 'u' suffix to the
TTL constants to ensure the correct unsigned type is used and to avoid
undefined behavior if these functions are implemented as macros using
bit shifts.

Signed-off-by: default avatarTim Pambor <tim.pambor@codewrights.de>
parent 659382f1
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment