The SWORD Project
1.9.0.svnversion
|
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <errno.h>
#include <ctype.h>
#include "ftplib.h"
Go to the source code of this file.
Classes | |
struct | NetBuf |
Macros | |
#define | ACCEPT_TIMEOUT 10 |
#define | BUILDING_LIBRARY |
#define | FTPLIB_BUFSIZ 8192 |
#define | FTPLIB_CONTROL 0 |
#define | FTPLIB_DEFMODE FTPLIB_PASSIVE |
#define | FTPLIB_READ 1 |
#define | FTPLIB_WRITE 2 |
#define | lllog(M) fprintf(stderr, M); |
#define | SETSOCKOPT_OPTVAL_TYPE (void *) |
Functions | |
static int | FtpAcceptConnection (netbuf *nData, netbuf *nControl) |
GLOBALDEF int | FtpAccess (const char *path, int typ, int mode, netbuf *nControl, netbuf **nData) |
GLOBALDEF int | FtpCDUp (netbuf *nControl) |
GLOBALDEF int | FtpChdir (const char *path, netbuf *nControl) |
GLOBALDEF int | FtpClose (netbuf *nData) |
GLOBALDEF int | FtpConnect (const char *host, netbuf **nControl) |
GLOBALDEF int | FtpDelete (const char *fnm, netbuf *nControl) |
GLOBALDEF int | FtpDir (const char *outputfile, const char *path, netbuf *nControl) |
GLOBALDEF int | FtpGet (const char *outputfile, const char *path, char mode, netbuf *nControl) |
GLOBALDEF void | FtpInit (void) |
GLOBALDEF char * | FtpLastResponse (netbuf *nControl) |
GLOBALDEF int | FtpLogin (const char *user, const char *pass, netbuf *nControl) |
GLOBALDEF int | FtpMkdir (const char *path, netbuf *nControl) |
GLOBALDEF int | FtpModDate (const char *path, char *dt, int max, netbuf *nControl) |
GLOBALDEF int | FtpNlst (const char *outputfile, const char *path, netbuf *nControl) |
static int | FtpOpenPort (netbuf *nControl, netbuf **nData, int mode, int dir) |
GLOBALDEF int | FtpOptions (int opt, long val, netbuf *nControl) |
GLOBALDEF int | FtpPut (const char *inputfile, const char *path, char mode, netbuf *nControl) |
GLOBALDEF int | FtpPwd (char *path, int max, netbuf *nControl) |
GLOBALDEF void | FtpQuit (netbuf *nControl) |
GLOBALDEF int | FtpRead (void *buf, int max, netbuf *nData) |
GLOBALDEF int | FtpRename (const char *src, const char *dst, netbuf *nControl) |
GLOBALDEF int | FtpRmdir (const char *path, netbuf *nControl) |
static int | FtpSendCmd (const char *cmd, char expresp, netbuf *nControl) |
GLOBALDEF int | FtpSite (const char *cmd, netbuf *nControl) |
GLOBALDEF int | FtpSize (const char *path, int *size, char mode, netbuf *nControl) |
GLOBALDEF int | FtpSysType (char *buf, int max, netbuf *nControl) |
GLOBALDEF int | FtpWrite (void *buf, int len, netbuf *nData) |
static int | FtpXfer (const char *localfile, const char *path, netbuf *nControl, int typ, int mode) |
void * | mymemccpy (void *dst, const void *src, int c, size_t n) |
static int | readline (char *buf, int max, netbuf *ctl) |
static int | readresp (char c, netbuf *nControl) |
static int | socket_wait (netbuf *ctl) |
static int | writeline (char *buf, int len, netbuf *nData) |
Variables | |
GLOBALDEF int | ftplib_debug = 0 |
#define FTPLIB_DEFMODE FTPLIB_PASSIVE |
GLOBALDEF int FtpAccess | ( | const char * | path, |
int | typ, | ||
int | mode, | ||
netbuf * | nControl, | ||
netbuf ** | nData | ||
) |
Definition at line 920 of file ftplib.c.
GLOBALDEF int FtpCDUp | ( | netbuf * | nControl | ) |
Definition at line 1168 of file ftplib.c.
Definition at line 1151 of file ftplib.c.
GLOBALDEF int FtpClose | ( | netbuf * | nData | ) |
Definition at line 1054 of file ftplib.c.
Definition at line 1397 of file ftplib.c.
Definition at line 1296 of file ftplib.c.
Definition at line 1354 of file ftplib.c.
Definition at line 675 of file ftplib.c.
Definition at line 1134 of file ftplib.c.
Definition at line 1334 of file ftplib.c.
Definition at line 1285 of file ftplib.c.
Definition at line 698 of file ftplib.c.
GLOBALDEF int FtpOptions | ( | int | opt, |
long | val, | ||
netbuf * | nControl | ||
) |
Definition at line 604 of file ftplib.c.
Definition at line 1365 of file ftplib.c.
GLOBALDEF int FtpPwd | ( | char * | path, |
int | max, | ||
netbuf * | nControl | ||
) |
Definition at line 1197 of file ftplib.c.
GLOBALDEF void FtpQuit | ( | netbuf * | nControl | ) |
Definition at line 1414 of file ftplib.c.
GLOBALDEF int FtpRead | ( | void * | buf, |
int | max, | ||
netbuf * | nData | ||
) |
Definition at line 1376 of file ftplib.c.
Definition at line 1180 of file ftplib.c.
Definition at line 1094 of file ftplib.c.
Definition at line 1306 of file ftplib.c.
GLOBALDEF int FtpSysType | ( | char * | buf, |
int | max, | ||
netbuf * | nControl | ||
) |
Definition at line 1115 of file ftplib.c.
GLOBALDEF int FtpWrite | ( | void * | buf, |
int | len, | ||
netbuf * | nData | ||
) |
|
static |
Definition at line 1219 of file ftplib.c.
void* mymemccpy | ( | void * | dst, |
const void * | src, | ||
int | c, | ||
size_t | n | ||
) |
|
static |
|
static |