I've noticed that commands like cp, for example, will fail silently when they encounter an error such as ENOSPC on a filesystem.
I've added and tested adding a simple addition equivalent of if (len == -1) perror_exit("write error"); in xsendfile to trap the error and re-ran the full test suite and haven't noticed any glaring issues and it does fix that cp problem.
I also noticed tar was using sendfile_len directly instead of xsendfile_len. Not sure if this is an issue in practice.
I've noticed that commands like cp, for example, will fail silently when they encounter an error such as ENOSPC on a filesystem.
I've added and tested adding a simple addition equivalent of
if (len == -1) perror_exit("write error");
in xsendfile to trap the error and re-ran the full test suite and haven't noticed any glaring issues and it does fix that cp problem.I also noticed tar was using sendfile_len directly instead of xsendfile_len. Not sure if this is an issue in practice.