diff options
Diffstat (limited to 'sftp-client.h')
-rw-r--r-- | sftp-client.h | 29 |
1 files changed, 22 insertions, 7 deletions
diff --git a/sftp-client.h b/sftp-client.h index c8a41f377..edb46790f 100644 --- a/sftp-client.h +++ b/sftp-client.h | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: sftp-client.h,v 1.14 2005/04/26 12:59:02 jmc Exp $ */ | 1 | /* $OpenBSD: sftp-client.h,v 1.17 2008/06/08 20:15:29 dtucker Exp $ */ |
2 | 2 | ||
3 | /* | 3 | /* |
4 | * Copyright (c) 2001-2004 Damien Miller <djm@openbsd.org> | 4 | * Copyright (c) 2001-2004 Damien Miller <djm@openbsd.org> |
@@ -30,6 +30,24 @@ struct SFTP_DIRENT { | |||
30 | }; | 30 | }; |
31 | 31 | ||
32 | /* | 32 | /* |
33 | * Used for statvfs responses on the wire from the server, because the | ||
34 | * server's native format may be larger than the client's. | ||
35 | */ | ||
36 | struct sftp_statvfs { | ||
37 | u_int64_t f_bsize; | ||
38 | u_int64_t f_frsize; | ||
39 | u_int64_t f_blocks; | ||
40 | u_int64_t f_bfree; | ||
41 | u_int64_t f_bavail; | ||
42 | u_int64_t f_files; | ||
43 | u_int64_t f_ffree; | ||
44 | u_int64_t f_favail; | ||
45 | u_int64_t f_fsid; | ||
46 | u_int64_t f_flag; | ||
47 | u_int64_t f_namemax; | ||
48 | }; | ||
49 | |||
50 | /* | ||
33 | * Initialise a SSH filexfer connection. Returns NULL on error or | 51 | * Initialise a SSH filexfer connection. Returns NULL on error or |
34 | * a pointer to a initialized sftp_conn struct on success. | 52 | * a pointer to a initialized sftp_conn struct on success. |
35 | */ | 53 | */ |
@@ -61,9 +79,6 @@ Attrib *do_stat(struct sftp_conn *, char *, int); | |||
61 | /* Get file attributes of 'path' (does not follow symlinks) */ | 79 | /* Get file attributes of 'path' (does not follow symlinks) */ |
62 | Attrib *do_lstat(struct sftp_conn *, char *, int); | 80 | Attrib *do_lstat(struct sftp_conn *, char *, int); |
63 | 81 | ||
64 | /* Get file attributes of open file 'handle' */ | ||
65 | Attrib *do_fstat(struct sftp_conn *, char *, u_int, int); | ||
66 | |||
67 | /* Set file attributes of 'path' */ | 82 | /* Set file attributes of 'path' */ |
68 | int do_setstat(struct sftp_conn *, char *, Attrib *); | 83 | int do_setstat(struct sftp_conn *, char *, Attrib *); |
69 | 84 | ||
@@ -73,15 +88,15 @@ int do_fsetstat(struct sftp_conn *, char *, u_int, Attrib *); | |||
73 | /* Canonicalise 'path' - caller must free result */ | 88 | /* Canonicalise 'path' - caller must free result */ |
74 | char *do_realpath(struct sftp_conn *, char *); | 89 | char *do_realpath(struct sftp_conn *, char *); |
75 | 90 | ||
91 | /* Get statistics for filesystem hosting file at "path" */ | ||
92 | int do_statvfs(struct sftp_conn *, const char *, struct sftp_statvfs *, int); | ||
93 | |||
76 | /* Rename 'oldpath' to 'newpath' */ | 94 | /* Rename 'oldpath' to 'newpath' */ |
77 | int do_rename(struct sftp_conn *, char *, char *); | 95 | int do_rename(struct sftp_conn *, char *, char *); |
78 | 96 | ||
79 | /* Rename 'oldpath' to 'newpath' */ | 97 | /* Rename 'oldpath' to 'newpath' */ |
80 | int do_symlink(struct sftp_conn *, char *, char *); | 98 | int do_symlink(struct sftp_conn *, char *, char *); |
81 | 99 | ||
82 | /* Return target of symlink 'path' - caller must free result */ | ||
83 | char *do_readlink(struct sftp_conn *, char *); | ||
84 | |||
85 | /* XXX: add callbacks to do_download/do_upload so we can do progress meter */ | 100 | /* XXX: add callbacks to do_download/do_upload so we can do progress meter */ |
86 | 101 | ||
87 | /* | 102 | /* |