10 * ----------------------------------------------------------------------------
11 * "THE BEER-WARE LICENSE" (Revision 42):
12 * <phk@FreeBSD.org> wrote this file. As long as you retain this notice you
13 * can do whatever you want with this stuff. If we meet some day, and you think
14 * this stuff is worth it, you can buy me a beer in return. Poul-Henning Kamp
15 * ----------------------------------------------------------------------------
22 * Turned inside out. Now returns xfers as new file ids, not as a special
28 /* Internal housekeeping data structure for FTP sessions */
30 enum { init, isopen, quit } con_state;
41 /* Structure we use to match FTP error codes with readable strings */
48 extern struct ftperr ftpErrList[];
49 extern int const ftpErrListLength;
51 /* Exported routines - deal only with FILE* type */
52 extern FILE *ftpLogin(char *host, char *user, char *passwd, int port, int verbose, int *retcode);
53 extern int ftpChdir(FILE *fp, char *dir);
54 extern int ftpErrno(FILE *fp);
55 extern off_t ftpGetSize(FILE *fp, char *file);
56 extern FILE *ftpGet(FILE *fp, char *file, off_t *seekto);
57 extern FILE *ftpPut(FILE *fp, char *file);
58 extern int ftpAscii(FILE *fp);
59 extern int ftpBinary(FILE *fp);
60 extern int ftpPassive(FILE *fp, int status);
61 extern void ftpVerbose(FILE *fp, int status);
62 extern FILE *ftpGetURL(char *url, char *user, char *passwd, int *retcode);
63 extern FILE *ftpPutURL(char *url, char *user, char *passwd, int *retcode);
64 extern time_t ftpGetModtime(FILE *fp, char *s);
65 extern const char *ftpErrString(int error);
66 extern FILE *ftpLoginAf(char *host, int af, char *user, char *passwd, int port, int verbose, int *retcode);
67 extern FILE *ftpGetURLAf(char *url, int af, char *user, char *passwd, int *retcode);
68 extern FILE *ftpPutURLAf(char *url, int af, char *user, char *passwd, int *retcode);
71 #endif /* _FTP_H_INCLUDE */