#include <sys/types.h>
+#include <sys/statvfs.h>
#include <stdio.h>
#include <unistd.h>
#include <string.h>
char * p;
char path[2048];
struct stat statbuf;
- struct smbc_statvfs statvfsbuf;
+ struct statvfs statvfsbuf;
smbc_init(get_auth_data_fn, debug);
#include <sys/types.h>
+#include <sys/statvfs.h>
#include <stdio.h>
#include <unistd.h>
#include <string.h>
char * p;
char path[2048];
struct stat statbuf;
- struct smbc_statvfs statvfsbuf;
+ struct statvfs statvfsbuf;
smbc_init(get_auth_data_fn, debug);
int
SMBC_statvfs_ctx(SMBCCTX *context,
char *path,
- struct smbc_statvfs *st);
+ struct statvfs *st);
int
SMBC_fstatvfs_ctx(SMBCCTX *context,
SMBCFILE *file,
- struct smbc_statvfs *st);
+ struct statvfs *st);
/* Functions in libsmb_xattr.c */
/* Make sure we have the following includes for now ... */
#include <sys/types.h>
#include <sys/stat.h>
+#include <sys/statvfs.h>
#include <fcntl.h>
#include <utime.h>
SMBC_ENCRYPTLEVEL_REQUIRE = 2
} smbc_smb_encrypt_level;
-/**
- * Use a system independent statvfs struct for smbclient.
- */
-struct smbc_statvfs {
- fsblkcnt_t f_bavail;
- fsblkcnt_t f_bfree;
- fsblkcnt_t f_blocks;
- fsfilcnt_t f_favail;
- fsfilcnt_t f_ffree;
- fsfilcnt_t f_files;
- unsigned long f_bsize;
- unsigned long f_flag;
- unsigned long f_frsize;
- unsigned long f_fsid;
- unsigned long f_namemax;
-};
/**
* Capabilities set in the f_flag field of struct statvfs, from
typedef int (*smbc_statvfs_fn)(SMBCCTX *c,
char *path,
- struct smbc_statvfs *st);
+ struct statvfs *st);
smbc_statvfs_fn smbc_getFunctionStatVFS(SMBCCTX *c);
void smbc_setFunctionStatVFS(SMBCCTX *c, smbc_statvfs_fn fn);
typedef int (*smbc_fstatvfs_fn)(SMBCCTX *c,
SMBCFILE *file,
- struct smbc_statvfs *st);
+ struct statvfs *st);
smbc_fstatvfs_fn smbc_getFunctionFstatVFS(SMBCCTX *c);
void smbc_setFunctionFstatVFS(SMBCCTX *c, smbc_fstatvfs_fn fn);
*/
int
smbc_statvfs(char *url,
- struct smbc_statvfs *st);
+ struct statvfs *st);
/**@ingroup attribute
* Get file system information via an file descriptor.
*/
int
smbc_fstatvfs(int fd,
- struct smbc_statvfs *st);
+ struct statvfs *st);
/**@ingroup attribute
int
smbc_statvfs(char *path,
- struct smbc_statvfs *st)
+ struct statvfs *st)
{
return smbc_getFunctionStatVFS(statcont)(statcont, path, st);
}
int
smbc_fstatvfs(int fd,
- struct smbc_statvfs *st)
+ struct statvfs *st)
{
SMBCFILE * file = find_fd(fd);
return smbc_getFunctionFstatVFS(statcont)(statcont, file, st);
int
SMBC_statvfs_ctx(SMBCCTX *context,
char *path,
- struct smbc_statvfs *st)
+ struct statvfs *st)
{
int ret;
bool bIsDir;
int
SMBC_fstatvfs_ctx(SMBCCTX *context,
SMBCFILE *file,
- struct smbc_statvfs *st)
+ struct statvfs *st)
{
uint32 fs_attrs = 0;
struct cli_state *cli = file->srv->cli;