summaryrefslogtreecommitdiffstats
path: root/lib/libftp/utils/uftp.h
blob: 3e7b3fe9b5b1d3a3247b4647ce052c7931e08f23 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
#include <FtpLibrary.h>
#include <strings.h>
#include <setjmp.h>
#include <signal.h>
#include <sys/types.h>
#include <sys/wait.h>
#include <sys/file.h>
#include <arpa/telnet.h>
#include <pwd.h>
#include <errno.h>
#include <glob.h>


#define SYSTEMRC "/usr/share/etc/uftprc"
#define LINK ftp[frame]
#define NFRAMES 10
#define TIME(proc) settimer(), status = proc , showtimer(), status
#define ARGS char *w1,char *w2,char *w3,char *w4,char *w5,char *w6
#define log(x) FtpLog("uftp",x)

typedef struct
{
  String host;
  String user;
  String pass;
  String pwd;
  int lock;
} LINKINFO;

typedef struct
{
  char *cmd;
  int (*func)();
  int need;
  char *help;
} CMDS;

typedef struct _alias
{
  String name,str;
  struct _alias *next;
} ALIAS;

extern ALIAS *firstalias;
extern FTP *ftp[NFRAMES];
extern LINKINFO iftp[NFRAMES];
extern int frame;
extern int lastcmd;
extern int glassmode;
extern int trymode;
extern int hashmode;
extern int restmode;
extern int sleeptime;
extern time_t noopinterval,nooptimeout;
extern CMDS cmds[];
extern int status;
extern String prompt;
extern String defaultuser;
extern jmp_buf start;

char *word(char *,int);
char *readline(char *);
char *getpass(char *);
char *getrcname();
char *getaliasrcname();
char *makestr();
char *expandalias(char *str);
char *getprompt();
char *makefilename(char *,char *);

void intr(int);
void noop();
int myhash(FTP *,unsigned int);
STATUS my_error(FTP *, int, char *);









OpenPOWER on IntegriCloud