HomeFreeBSD

MFC r313821 r315277 r315286

Description

MFC r313821 r315277 r315286

Use inet_ntoa_r() instead of inet_ntoa() throughout the kernel.

inet_ntoa() cannot be used safely in a multithreaded environment
because it uses a static local buffer. Instead, use inet_ntoa_r()
with a buffer on the caller's stack, except for KTR messages.
KTR can correctly log the immediate integral values passed to it,
as well as constant strings, but not non-constant strings,
since they might change by the time ktrdump retrieves them.
Therefore, use hex notation in KTR messages.

Sponsored by: Dell EMC

Details

Provenance
vangyzenAuthored on
Parents
rS315455: r308996 broke IP literals by assuming that a colon could only occur as
Branches
Unknown
Tags
Unknown