From 5054db1859039e8f86a723728f570ed32a47fe24 Mon Sep 17 00:00:00 2001 From: Ingo Weinhold Date: Sun, 3 Aug 2008 01:55:25 +0000 Subject: [PATCH] * Use vfs_vnode_io() to schedule subrequests instead of calling the FS's io() hook directly (it might not even have one). * Fixed incorrect check in synchronous_io() which would cause requests with more than one vec to finish early. Fixes bug #2558. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@26751 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- src/system/kernel/fs/vfs_request_io.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/system/kernel/fs/vfs_request_io.cpp b/src/system/kernel/fs/vfs_request_io.cpp index 4834dacd79..fda774077c 100644 --- a/src/system/kernel/fs/vfs_request_io.cpp +++ b/src/system/kernel/fs/vfs_request_io.cpp @@ -210,7 +210,7 @@ do_iterative_fd_io_iterate(void* _cookie, io_request* request, if (error == B_OK) { TRACE_RIO("[%ld] scheduling subrequest: %p\n", find_thread(NULL), subRequest); - error = FS_CALL(cookie->vnode, io, cookie->descriptor->cookie, + error = vfs_vnode_io(cookie->vnode, cookie->descriptor->cookie, subRequest); } else { // Once scheduling a subrequest failed, we cancel all subsequent @@ -335,7 +335,7 @@ synchronous_io(io_request* request, DoIO& io) offset += transferred; length -= transferred; - if (transferred != length) + if (transferred != vecLength) break; }