try to make ftp work
This commit is contained in:
parent
9e36143a34
commit
54eacd0b20
1 changed files with 4 additions and 9 deletions
|
|
@ -856,23 +856,18 @@ doftp(URL *u, URL *px, Range *r, Out *out, long mtime)
|
||||||
int pid, ctl, data, rv;
|
int pid, ctl, data, rv;
|
||||||
Waitmsg *w;
|
Waitmsg *w;
|
||||||
char msg[64];
|
char msg[64];
|
||||||
char conndir[NETPATHLEN];
|
|
||||||
char *p;
|
|
||||||
|
|
||||||
/* untested, proxy dosn't work with ftp (I think) */
|
/* untested, proxy dosn't work with ftp (I think) */
|
||||||
if(px->host == nil){
|
if(px->host == nil){
|
||||||
ctl = dial(netmkaddr(u->host, tcpdir, u->port), 0, conndir, 0);
|
ctl = dial(netmkaddr(u->host, tcpdir, u->port), 0, 0, 0);
|
||||||
} else {
|
} else {
|
||||||
ctl = dial(netmkaddr(px->host, tcpdir, px->port), 0, conndir, 0);
|
ctl = dial(netmkaddr(px->host, tcpdir, px->port), 0, 0, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
if(ctl < 0)
|
if(ctl < 0)
|
||||||
return Error;
|
return Error;
|
||||||
if(net == nil){
|
if(net == nil)
|
||||||
p = strrchr(conndir, '/');
|
strcpy(tcpdir, "tcp");
|
||||||
*p = 0;
|
|
||||||
snprint(tcpdir, sizeof(tcpdir), conndir);
|
|
||||||
}
|
|
||||||
|
|
||||||
initibuf();
|
initibuf();
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue