diff options
Diffstat (limited to 'release/sysinstall/ftp.h')
-rw-r--r-- | release/sysinstall/ftp.h | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/release/sysinstall/ftp.h b/release/sysinstall/ftp.h new file mode 100644 index 0000000..f1e35d6 --- /dev/null +++ b/release/sysinstall/ftp.h @@ -0,0 +1,29 @@ +#ifndef _FTP_H_INCLUDE +#define _FTP_H_INCLUDE + +typedef struct { + enum {init, isopen, xfer} state; + int fd_ctrl; + int fd_xfer; + int fd_debug; + int binary; + int passive; + int addrtype; + char *host; + char *file; +} *FTP_t; + +FTP_t FtpInit(); +int FtpOpen(FTP_t, char *host, char *user, char *passwd); +#define FtpBinary(ftp,bool) { (ftp)->binary = (bool); } +#define FtpPassive(ftp,bool) { (ftp)->passive = (bool); } +#ifndef STANDALONE_FTP +#define FtpDebug(ftp, bool) { (ftp)->fd_debug = (bool); } +#endif +int FtpChdir(FTP_t, char *); +int FtpGet(FTP_t, char *); +int FtpEOF(FTP_t); +void FtpClose(FTP_t); + +#endif +/* _FTP_H_INCLUDE */ |