Viktor Dukhovni: > On Sun, Feb 15, 2015 at 03:44:45PM -0500, Wietse Venema wrote: > > > Viktor Dukhovni: > > > On Sun, Feb 15, 2015 at 02:08:58PM -0500, Wietse Venema wrote: > > > > > > > Excellent. We narrowed down the problem to the VSTREAM_GETC() call, > > > > established why the call failed, and I added logging in so that > > > > this will be easier to diagnose in the future. > > > > > > Should there be an explicit flush after the attr_vprint()? Otherwise, > > > write errors will instead be reported as read errors after attr_scan() > > > fails to flush the output buffer... > > > > Given that cyles are finite, we cannot achieve perfection in every > > respect. What do we optimize for? > > That's the question really. I am not sure the warnings for such > rare kernel bugs are worth the trouble at all, but if we're bothering > to do them, I'm somewhat inclined to report reasonably accurate > symtoms. Otherwise, just rely on strace and the like to tell the > complete story.
It's the the 90%-10% rule (sometimes called 80%-20%). The problem was a total lack of "errno" logging. That has now been addressed. The 90% result (at 10% of the effort) is better than keeping the people in total darkness and telling them to run strace on unfamiliar code. Instead of adding redundant "flush" calls to make error logging perfectly accurate, the effort is better spent addressing the larger problem that some errors are detected but not logged with the errno and the name of the target. Wietse