summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
authorChristof Schmitt <cs@samba.org>2014-12-10 15:33:23 -0700
committerChristof Schmitt <cs@samba.org>2015-03-02 22:31:08 +0100
commiteefb916192d7e58c21bee35ef3420a4b3f0a3ae0 (patch)
tree9648158ce8b38b8e539ac6c1469fae4b9cd0254c /source3
parent15c2b3a825b2f24629d1bc22d2bdcfec494cde13 (diff)
downloadsamba-eefb916192d7e58c21bee35ef3420a4b3f0a3ae0.tar.gz
gpfs: Rename wrapper for gpfs_ftruncate
Signed-off-by: Christof Schmitt <cs@samba.org> Reviewed-by: Ralph Böhme <slow@samba.org>
Diffstat (limited to 'source3')
-rw-r--r--source3/modules/gpfs.c20
-rw-r--r--source3/modules/vfs_gpfs.c2
-rw-r--r--source3/modules/vfs_gpfs.h2
3 files changed, 12 insertions, 12 deletions
diff --git a/source3/modules/gpfs.c b/source3/modules/gpfs.c
index eb200ff25f6..f67b38c5f0f 100644
--- a/source3/modules/gpfs.c
+++ b/source3/modules/gpfs.c
@@ -169,6 +169,16 @@ int gpfswrap_prealloc(int fd, gpfs_off64_t start, gpfs_off64_t bytes)
return gpfs_prealloc_fn(fd, start, bytes);
}
+int gpfswrap_ftruncate(int fd, gpfs_off64_t length)
+{
+ if (gpfs_ftruncate_fn == NULL) {
+ errno = ENOSYS;
+ return -1;
+ }
+
+ return gpfs_ftruncate_fn(fd, length);
+}
+
bool set_gpfs_sharemode(files_struct *fsp, uint32 access_mask,
uint32 share_access)
{
@@ -234,16 +244,6 @@ int set_gpfs_lease(int fd, int leasetype)
return gpfswrap_set_lease(fd, gpfs_type);
}
-int smbd_gpfs_ftruncate(int fd, gpfs_off64_t length)
-{
- if (gpfs_ftruncate_fn == NULL) {
- errno = ENOSYS;
- return -1;
- }
-
- return gpfs_ftruncate_fn(fd, length);
-}
-
int get_gpfs_quota(const char *pathname, int type, int id,
struct gpfs_quotaInfo *qi)
{
diff --git a/source3/modules/vfs_gpfs.c b/source3/modules/vfs_gpfs.c
index 88608039066..03cded11bc5 100644
--- a/source3/modules/vfs_gpfs.c
+++ b/source3/modules/vfs_gpfs.c
@@ -1787,7 +1787,7 @@ static int vfs_gpfs_ftruncate(vfs_handle_struct *handle, files_struct *fsp,
return SMB_VFS_NEXT_FTRUNCATE(handle, fsp, len);
}
- result = smbd_gpfs_ftruncate(fsp->fh->fd, len);
+ result = gpfswrap_ftruncate(fsp->fh->fd, len);
if ((result == -1) && (errno == ENOSYS)) {
return SMB_VFS_NEXT_FTRUNCATE(handle, fsp, len);
}
diff --git a/source3/modules/vfs_gpfs.h b/source3/modules/vfs_gpfs.h
index 83a4a612d92..3e040227e03 100644
--- a/source3/modules/vfs_gpfs.h
+++ b/source3/modules/vfs_gpfs.h
@@ -38,10 +38,10 @@ int gpfswrap_set_winattrs_path(char *pathname, int flags,
int gpfswrap_get_winattrs_path(char *pathname, struct gpfs_winattr *attrs);
int gpfswrap_get_winattrs(int fd, struct gpfs_winattr *attrs);
int gpfswrap_prealloc(int fd, gpfs_off64_t start, gpfs_off64_t bytes);
+int gpfswrap_ftruncate(int fd, gpfs_off64_t length);
bool set_gpfs_sharemode(files_struct *fsp, uint32 access_mask,
uint32 share_access);
int set_gpfs_lease(int fd, int leasetype);
-int smbd_gpfs_ftruncate(int fd, gpfs_off64_t length);
int get_gpfs_quota(const char *pathname, int type, int id,
struct gpfs_quotaInfo *qi);
int get_gpfs_fset_id(const char *pathname, int *fset_id);