From: Mike Yuan Date: Thu, 7 Dec 2023 16:49:17 +0000 (+0800) Subject: various: don't log synthetic EIO for fwrite X-Git-Tag: v256-rc1~1556 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=513412a69cdd44dc95f83de26bbca2a184121926;p=thirdparty%2Fsystemd.git various: don't log synthetic EIO for fwrite Follow-up for f9568765d4d3d57de1ec01d85f0a0682920f4d10 --- diff --git a/src/creds/creds.c b/src/creds/creds.c index 7a98a5dcd34..10d117118fb 100644 --- a/src/creds/creds.c +++ b/src/creds/creds.c @@ -350,7 +350,7 @@ static int write_blob(FILE *f, const void *data, size_t size) { } if (fwrite(data, 1, size, f) != size) - return log_error_errno(SYNTHETIC_ERRNO(EIO), "Failed to write credential data: %m"); + return log_error_errno(SYNTHETIC_ERRNO(EIO), "Failed to write credential data."); r = print_newline(f, data, size); if (r < 0) diff --git a/src/shared/edit-util.c b/src/shared/edit-util.c index 2662b2bf1b3..fb9bdbc1601 100644 --- a/src/shared/edit-util.c +++ b/src/shared/edit-util.c @@ -206,7 +206,7 @@ static int create_edit_temp_file(EditFile *e, const char *contents, size_t conte if (e->context->stdin) { if (fwrite(contents, 1, contents_size, f) != contents_size) return log_error_errno(SYNTHETIC_ERRNO(EIO), - "Failed to copy input to temporary file '%s': %m", temp); + "Failed to copy input to temporary file '%s'.", temp); } else { r = populate_edit_temp_file(e, f, temp); if (r < 0)