Skip to content
Snippets Groups Projects
Simon McVittie's avatar
Simon McVittie authored
`warn(fmt, args)` is equivalent to (pseudocode)
`warnx(fmt + ": %s", args, strerror(errno))`. In contexts where we do
not have a useful value for errno, or where we are showing an error
message that should already contain a previous result of strerror, we
should use warnx() instead. This avoids showing a misleading errno
which might have been set for some unrelated reason.

Prompted by jupiter/tasks#887.

Signed-off-by: default avatarSimon McVittie <smcv@collabora.com>
6ff340cb
History