do_preadv and do_pwritev all have a 'buffer_size' argument, but they
never used it. Instead of it, they use global 'buffersize' variable,
which is initialized in alloc_buffer(). As the 'buffer_size' is
useless, so remove it for clear code.
Signed-off-by: Zorro Lang <zlang@redhat.com>
Reviewed-by: Eric Sandeen <sandeen@redhat.com>
Signed-off-by: Eric Sandeen <sandeen@sandeen.net>
do_preadv(
int fd,
off64_t offset,
- size_t count,
- size_t buffer_size)
+ size_t count)
{
int vecs = 0;
ssize_t oldlen = 0;
return bytes;
}
#else
-#define do_preadv(fd, offset, count, buffer_size) (0)
+#define do_preadv(fd, offset, count) (0)
#endif
static ssize_t
if (!vectors)
return pread(fd, buffer, min(count, buffer_size), offset);
- return do_preadv(fd, offset, count, buffer_size);
+ return do_preadv(fd, offset, count);
}
static int
int fd,
off64_t offset,
size_t count,
- size_t buffer_size,
int pwritev2_flags)
{
int vecs = 0;
return bytes;
}
#else
-#define do_pwritev(fd, offset, count, buffer_size, pwritev2_flags) (0)
+#define do_pwritev(fd, offset, count, pwritev2_flags) (0)
#endif
static ssize_t
if (!vectors)
return pwrite(fd, buffer, min(count, buffer_size), offset);
- return do_pwritev(fd, offset, count, buffer_size, pwritev2_flags);
+ return do_pwritev(fd, offset, count, pwritev2_flags);
}
static int