Description
In src/lib.rs, the error message for wrong SNTP version uses {vn} as a literal string instead of interpolating the variable:
return Err(Error::new(
ErrorKind::Other,
"Server returned wrong SNTP version {vn}, expected 4.",
));
This will output the literal text {vn} instead of the actual version number.
Suggested fix
Wrap with format!():
return Err(Error::new(
ErrorKind::Other,
format!("Server returned wrong SNTP version {vn}, expected 4."),
));
Description
In
src/lib.rs, the error message for wrong SNTP version uses{vn}as a literal string instead of interpolating the variable:This will output the literal text
{vn}instead of the actual version number.Suggested fix
Wrap with
format!():