Skip to content
Commit 9468cb6e authored by Jan Van Winkel's avatar Jan Van Winkel Committed by Jukka Rissanen
Browse files

tests: net: hostname: Corrected unique hostname conversion



Replaced net_bytes_from_str in hostname_get test by a new function that
converts the unique part of the hostname in a byte array.

net_bytes_from_str can not be used as it assumes that the string input
is of the format "xx:xx:xx:xx:xx:xx" where as the unique part of the
hostname is a MAC address string without colons. If net_bytes_from_str
is used this could result in buffer overrun on the input string.

Signed-off-by: default avatarJan Van Winkel <jan.van_winkel@dxplore.eu>
parent 391076c7
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment