diff options
author | Damien Miller <djm@cvs.openbsd.org> | 2001-03-13 22:42:56 +0000 |
---|---|---|
committer | Damien Miller <djm@cvs.openbsd.org> | 2001-03-13 22:42:56 +0000 |
commit | 6d33235655eca09932be47907b439e1882e14956 (patch) | |
tree | 6b02eb7450117913fae04bd807fce9f40e331f77 /usr.bin/ssh/sftp-client.h | |
parent | 9da0c238faae60383680a06e77bfc217150f8b90 (diff) |
sftp client filename globbing for get, put, ch{mod,grp,own}. ok markus@
Diffstat (limited to 'usr.bin/ssh/sftp-client.h')
-rw-r--r-- | usr.bin/ssh/sftp-client.h | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/usr.bin/ssh/sftp-client.h b/usr.bin/ssh/sftp-client.h index e836c0d668d..e7ba02ad615 100644 --- a/usr.bin/ssh/sftp-client.h +++ b/usr.bin/ssh/sftp-client.h @@ -1,4 +1,4 @@ -/* $OpenBSD: sftp-client.h,v 1.2 2001/03/07 10:11:23 djm Exp $ */ +/* $OpenBSD: sftp-client.h,v 1.3 2001/03/13 22:42:54 djm Exp $ */ /* * Copyright (c) 2001 Damien Miller. All rights reserved. @@ -26,6 +26,14 @@ /* Client side of SSH2 filexfer protocol */ +typedef struct SFTP_DIRENT SFTP_DIRENT; + +struct SFTP_DIRENT { + char *filename; + char *longname; + Attrib a; +}; + /* * Initialiase a SSH filexfer connection. Returns -1 on error or * protocol version on success. @@ -38,6 +46,12 @@ int do_close(int fd_in, int fd_out, char *handle, u_int handle_len); /* List contents of directory 'path' to stdout */ int do_ls(int fd_in, int fd_out, char *path); +/* Read contents of 'path' to NULL-terminated array 'dir' */ +int do_readdir(int fd_in, int fd_out, char *path, SFTP_DIRENT ***dir); + +/* Frees a NULL-terminated array of SFTP_DIRENTs (eg. from do_readdir) */ +void free_sftp_dirents(SFTP_DIRENT **s); + /* Delete file 'path' */ int do_rm(int fd_in, int fd_out, char *path); |