summaryrefslogtreecommitdiff
path: root/source3/modules
diff options
context:
space:
mode:
authorMichael Adam <obnox@samba.org>2008-01-11 00:56:06 +0100
committerMichael Adam <obnox@samba.org>2008-01-11 01:27:05 +0100
commit14d45bedfa844dfbf646e792d1cf84544997de25 (patch)
tree19dae30c5edb435ff4f70736c0eb883413f3bc58 /source3/modules
parent4caab9ca25e1163378714de825d835e79e27dd4f (diff)
downloadsamba-14d45bedfa844dfbf646e792d1cf84544997de25.tar.gz
samba-14d45bedfa844dfbf646e792d1cf84544997de25.tar.bz2
samba-14d45bedfa844dfbf646e792d1cf84544997de25.zip
Remove now redundant parameter fd from prime_cache().
Michael (This used to be commit 63acaf1b9755cd5be5342929e1210afa06e170f3)
Diffstat (limited to 'source3/modules')
-rw-r--r--source3/modules/vfs_cacheprime.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/source3/modules/vfs_cacheprime.c b/source3/modules/vfs_cacheprime.c
index 15c8167a07..be934f6bd6 100644
--- a/source3/modules/vfs_cacheprime.c
+++ b/source3/modules/vfs_cacheprime.c
@@ -48,7 +48,6 @@ static void * g_readbuf = NULL;
static bool prime_cache(
struct vfs_handle_struct * handle,
files_struct * fsp,
- int fd,
SMB_OFF_T offset,
size_t count)
{
@@ -75,7 +74,7 @@ static bool prime_cache(
MODULE, (long long)g_readsz, (long long)*last,
fsp->fsp_name));
- nread = sys_pread(fd, g_readbuf, g_readsz, *last);
+ nread = sys_pread(fsp->fh->fd, g_readbuf, g_readsz, *last);
if (nread < 0) {
*last = -1;
return False;
@@ -131,7 +130,7 @@ static ssize_t cprime_sendfile(
size_t count)
{
if (g_readbuf && offset == 0) {
- prime_cache(handle, fromfsp, fromfsp->fh->fd, offset, count);
+ prime_cache(handle, fromfsp, offset, count);
}
return SMB_VFS_NEXT_SENDFILE(handle, tofd, fromfsp,
@@ -148,7 +147,7 @@ static ssize_t cprime_read(
offset = SMB_VFS_LSEEK(fsp, 0, SEEK_CUR);
if (offset >= 0 && g_readbuf) {
- prime_cache(handle, fsp, fsp->fh->fd, offset, count);
+ prime_cache(handle, fsp, offset, count);
SMB_VFS_LSEEK(fsp, offset, SEEK_SET);
}
@@ -163,7 +162,7 @@ static ssize_t cprime_pread(
SMB_OFF_T offset)
{
if (g_readbuf) {
- prime_cache(handle, fsp, fsp->fh->fd, offset, count);
+ prime_cache(handle, fsp, offset, count);
}
return SMB_VFS_NEXT_PREAD(handle, fsp, data, count, offset);