mirror of
https://git.FreeBSD.org/src.git
synced 2024-11-30 08:19:09 +00:00
Fix the "only wrote -1 of 32768 bytes: Input/output error" error message.
This commit is contained in:
parent
fdace17f81
commit
de6a1361a5
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=146195
@ -630,8 +630,11 @@ write_file(int fd, struct track_info *track_info)
|
||||
track_info->block_size;
|
||||
}
|
||||
if ((res = write(fd, buf, count)) != count) {
|
||||
fprintf(stderr, "\nonly wrote %d of %jd bytes: %s\n",
|
||||
res, (intmax_t)count, strerror(errno));
|
||||
if (res == -1)
|
||||
fprintf(stderr, "\n%s\n", strerror(errno));
|
||||
else
|
||||
fprintf(stderr, "\nonly wrote %d of %jd"
|
||||
" bytes\n", res, (intmax_t)count);
|
||||
break;
|
||||
}
|
||||
size += count;
|
||||
|
Loading…
Reference in New Issue
Block a user