home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The Datafile PD-CD 3
/
PDCD_3.iso
/
internet
/
netlite
/
NET
/
h
/
SESSION
< prev
next >
Wrap
Text File
|
1993-04-10
|
1KB
|
43 lines
/* Session control structure; only one entry is used at a time */
struct session {
int type;
#define FREE 0
#define RESOLVING 1
#define TELNET 2
#define FTP 3
#define FINGER 4
#define PING 5
#define DEAD 6
char *name; /* Name of remote host */
int32 addr; /* Address of remote host */
union {
struct ftp *ftp;
struct telnet *telnet;
struct finger *finger;
struct ping *ping;
} cb;
void (*parse)(); /* Where to hand typed input when conversing */
void *window; /* Window handle */
int echo;
int raw;
int keypad;
#define BUFMAX 256
char buffer[BUFMAX];
char *bufptr;
};
#define NULLSESSION (struct session *)0
extern unsigned nsessions;
extern struct session *sessions;
/* In SESSION */
void session_close(struct session *);
void session_reset(struct session *);
void session_kick(struct session *);
void session_info(struct session *);
struct session *newsession(char *);
void detachsession(struct session *);
void freesession(struct session *);
extern int16 lport;