summaryrefslogtreecommitdiff
path: root/sftp-client.h
diff options
context:
space:
mode:
authorBen Lindstrom <mouring@eviladmin.org>2001-07-04 04:07:12 +0000
committerBen Lindstrom <mouring@eviladmin.org>2001-07-04 04:07:12 +0000
commitb4c774cf8878d9100fde92ff4e938671c3b0301b (patch)
treea2dff9a498a7c4cdeddace98c2c34c7a2e3689fb /sftp-client.h
parent16ae3d0dba5f81e5602798b915105284033dea75 (diff)
- itojun@cvs.openbsd.org 2001/06/26 06:33:07
[servconf.h serverloop.h session.h sftp-client.h sftp-common.h sftp-glob.h sftp-int.h sshconnect.h ssh-dss.h sshlogin.h sshpty.h ssh-rsa.h tildexpand.h uidswap.h uuencode.h xmalloc.h] prototype pedant. not very creative... - () -> (void) - no variable names
Diffstat (limited to 'sftp-client.h')
-rw-r--r--sftp-client.h44
1 files changed, 20 insertions, 24 deletions
diff --git a/sftp-client.h b/sftp-client.h
index 09ffcc05c..a322b2571 100644
--- a/sftp-client.h
+++ b/sftp-client.h
@@ -1,4 +1,4 @@
1/* $OpenBSD: sftp-client.h,v 1.5 2001/04/05 10:42:52 markus Exp $ */ 1/* $OpenBSD: sftp-client.h,v 1.6 2001/06/26 06:33:01 itojun Exp $ */
2 2
3/* 3/*
4 * Copyright (c) 2001 Damien Miller. All rights reserved. 4 * Copyright (c) 2001 Damien Miller. All rights reserved.
@@ -38,57 +38,55 @@ struct SFTP_DIRENT {
38 * Initialiase a SSH filexfer connection. Returns -1 on error or 38 * Initialiase a SSH filexfer connection. Returns -1 on error or
39 * protocol version on success. 39 * protocol version on success.
40 */ 40 */
41int do_init(int fd_in, int fd_out); 41int do_init(int, int);
42 42
43/* Close file referred to by 'handle' */ 43/* Close file referred to by 'handle' */
44int do_close(int fd_in, int fd_out, char *handle, u_int handle_len); 44int do_close(int, int, char *, u_int);
45 45
46/* List contents of directory 'path' to stdout */ 46/* List contents of directory 'path' to stdout */
47int do_ls(int fd_in, int fd_out, char *path); 47int do_ls(int, int, char *);
48 48
49/* Read contents of 'path' to NULL-terminated array 'dir' */ 49/* Read contents of 'path' to NULL-terminated array 'dir' */
50int do_readdir(int fd_in, int fd_out, char *path, SFTP_DIRENT ***dir); 50int do_readdir(int, int, char *, SFTP_DIRENT ***);
51 51
52/* Frees a NULL-terminated array of SFTP_DIRENTs (eg. from do_readdir) */ 52/* Frees a NULL-terminated array of SFTP_DIRENTs (eg. from do_readdir) */
53void free_sftp_dirents(SFTP_DIRENT **s); 53void free_sftp_dirents(SFTP_DIRENT **);
54 54
55/* Delete file 'path' */ 55/* Delete file 'path' */
56int do_rm(int fd_in, int fd_out, char *path); 56int do_rm(int, int, char *);
57 57
58/* Create directory 'path' */ 58/* Create directory 'path' */
59int do_mkdir(int fd_in, int fd_out, char *path, Attrib *a); 59int do_mkdir(int, int, char *, Attrib *);
60 60
61/* Remove directory 'path' */ 61/* Remove directory 'path' */
62int do_rmdir(int fd_in, int fd_out, char *path); 62int do_rmdir(int, int, char *);
63 63
64/* Get file attributes of 'path' (follows symlinks) */ 64/* Get file attributes of 'path' (follows symlinks) */
65Attrib *do_stat(int fd_in, int fd_out, char *path, int quiet); 65Attrib *do_stat(int, int, char *, int);
66 66
67/* Get file attributes of 'path' (does not follow symlinks) */ 67/* Get file attributes of 'path' (does not follow symlinks) */
68Attrib *do_lstat(int fd_in, int fd_out, char *path, int quiet); 68Attrib *do_lstat(int, int, char *, int);
69 69
70/* Get file attributes of open file 'handle' */ 70/* Get file attributes of open file 'handle' */
71Attrib *do_fstat(int fd_in, int fd_out, char *handle, u_int handle_len, 71Attrib *do_fstat(int, int, char *, u_int, int);
72 int quiet);
73 72
74/* Set file attributes of 'path' */ 73/* Set file attributes of 'path' */
75int do_setstat(int fd_in, int fd_out, char *path, Attrib *a); 74int do_setstat(int, int, char *, Attrib *);
76 75
77/* Set file attributes of open file 'handle' */ 76/* Set file attributes of open file 'handle' */
78int do_fsetstat(int fd_in, int fd_out, char *handle, 77int do_fsetstat(int, int, char *, u_int, Attrib *);
79 u_int handle_len, Attrib *a);
80 78
81/* Canonicalise 'path' - caller must free result */ 79/* Canonicalise 'path' - caller must free result */
82char *do_realpath(int fd_in, int fd_out, char *path); 80char *do_realpath(int, int, char *);
83 81
84/* Rename 'oldpath' to 'newpath' */ 82/* Rename 'oldpath' to 'newpath' */
85int do_rename(int fd_in, int fd_out, char *oldpath, char *newpath); 83int do_rename(int, int, char *, char *);
86 84
87/* Rename 'oldpath' to 'newpath' */ 85/* Rename 'oldpath' to 'newpath' */
88int do_symlink(int fd_in, int fd_out, char *oldpath, char *newpath); 86int do_symlink(int, int, char *, char *);
89 87
90/* Return target of symlink 'path' - caller must free result */ 88/* Return target of symlink 'path' - caller must free result */
91char *do_readlink(int fd_in, int fd_out, char *path); 89char *do_readlink(int, int, char *);
92 90
93/* XXX: add callbacks to do_download/do_upload so we can do progress meter */ 91/* XXX: add callbacks to do_download/do_upload so we can do progress meter */
94 92
@@ -96,12 +94,10 @@ char *do_readlink(int fd_in, int fd_out, char *path);
96 * Download 'remote_path' to 'local_path'. Preserve permissions and times 94 * Download 'remote_path' to 'local_path'. Preserve permissions and times
97 * if 'pflag' is set 95 * if 'pflag' is set
98 */ 96 */
99int do_download(int fd_in, int fd_out, char *remote_path, char *local_path, 97int do_download(int, int, char *, char *, int);
100 int pflag);
101 98
102/* 99/*
103 * Upload 'local_path' to 'remote_path'. Preserve permissions and times 100 * Upload 'local_path' to 'remote_path'. Preserve permissions and times
104 * if 'pflag' is set 101 * if 'pflag' is set
105 */ 102 */
106int do_upload(int fd_in, int fd_out, char *local_path, char *remote_path, 103int do_upload(int, int, char *, char *, int);
107 int pflag);