version 1.88, 2014/10/24 02:01:20 |
version 1.89, 2015/01/16 06:40:08 |
|
|
hookup(char *host, char *port) |
hookup(char *host, char *port) |
{ |
{ |
int s, tos, error; |
int s, tos, error; |
static char hostnamebuf[MAXHOSTNAMELEN]; |
static char hostnamebuf[HOST_NAME_MAX+1]; |
struct addrinfo hints, *res, *res0, *ares; |
struct addrinfo hints, *res, *res0, *ares; |
char hbuf[NI_MAXHOST]; |
char hbuf[NI_MAXHOST]; |
char *cause = "unknown"; |
char *cause = "unknown"; |
|
|
sig_t oldintr; |
sig_t oldintr; |
static struct comvars { |
static struct comvars { |
int connect; |
int connect; |
char name[MAXHOSTNAMELEN]; |
char name[HOST_NAME_MAX+1]; |
union sockunion mctl; |
union sockunion mctl; |
union sockunion hctl; |
union sockunion hctl; |
FILE *in; |
FILE *in; |
|
|
char nti[17]; |
char nti[17]; |
char nto[17]; |
char nto[17]; |
int mapflg; |
int mapflg; |
char mi[MAXPATHLEN]; |
char mi[PATH_MAX]; |
char mo[MAXPATHLEN]; |
char mo[PATH_MAX]; |
} proxstruct, tmpstruct; |
} proxstruct, tmpstruct; |
struct comvars *ip, *op; |
struct comvars *ip, *op; |
|
|
|
|
char * |
char * |
gunique(const char *local) |
gunique(const char *local) |
{ |
{ |
static char new[MAXPATHLEN]; |
static char new[PATH_MAX]; |
char *cp = strrchr(local, '/'); |
char *cp = strrchr(local, '/'); |
int d, count=0; |
int d, count=0; |
char ext = '1'; |
char ext = '1'; |