[Bug 53677] New: invalid O_WRONLY read sets errno=EACCES instead of EBADF