Files
mars-nwe/include/tools.h
Mario Fetka 44a309de40
All checks were successful
Source release / source-package (push) Successful in 45s
nwserv: escape SAP names in debug logs
SAP service names are fixed-size 48-byte fields and are not guaranteed to be
safe C strings in diagnostics.  Some NetWare 6.5 SAP service types advertise
non-printable or high-bit bytes in the name field, which made the debug log
hard to read and could run past the intended protocol field if logged with a
plain %s.

Add bounded formatting for SAP names used in debug output.  Stop at NUL within
the fixed field, keep printable ASCII unchanged, and escape other bytes as
\\xNN.

This is logging-only and does not change SAP/RIP protocol behavior.
2026-05-29 21:51:57 +02:00

3.2 KiB