I wrote:
> I think this is indisputably a bug in (some versions of) NetBSD. If I
> can seek past the end of file, read() shouldn't consider it a hard error
> to read there --- and in any case, EFAULT isn't a very reasonable error
> code to return. Since it seems not to be a widespread problem, I'm not
> eager to change the hash code to try to avoid it.
I forgot to mention a possible contributing factor: the files involved
were NFS-mounted, in the case I was looking at. So this may be an NFS
problem more than a NetBSD problem. Anyone want to try the given test
case on NFS-mounted files on other systems?
regards, tom lane