Maybe I didn't make it clear enough that fetch(1), and others uknown to
me, that use libftpio behave differently than ftp(1). I could imagine that
the current behaviour would cause confusion since ftp(1) checks the value
of FTP_PASSIVE_MODE and acts appropriately and programs using
libftpio do not.  My whole point was getting ftp(1) and programs using
libftpio to behave in the same manner.  Maybe I'm just not explaining it
right :), take a look at the following snippets...

>From src/usr.bin/ftp/main.c:
        if ((s = getenv("FTP_PASSIVE_MODE")) != NULL
            && strcasecmp(s, "no") != 0)
                passivemode = 1;
        if (strcmp(cp, "pftp") == 0)
                passivemode = 1;

>From src/lib/libftpio/ftpio.c
    if (getenv("FTP_PASSIVE_MODE"))
        ftpPassive(fp, TRUE);

You can see how they differ in handling FTP_PASSIVE_MODE.

Someone (sorry I can't remember your name :)) suggested a better
way of doing the if... take a look at:
http://quake.nyct.net/~efutch/FreeBSD/ftpio.c.patch-2

--
Eric Futch              New York Connect.Net, Ltd.
[EMAIL PROTECTED]         Technical Support Staff
http://www.nyct.net     (212) 293-2620
"Bringing New York The Internet Access It Deserves"


On Thu, 20 Apr 2000, Tim Liddelow wrote:

>Looking at the patch, the only mod I would suggest is to preserve the current
>behaviour;  make it set passive mode if the variable is just defined (without
>any value).  If it is NO, sure, dont set passive mode, but set passive  mode if
>the variable is YES or no value.  i.e. looking at the patch, change the last if
>statement to just if (cp) and don't do the strncmp().
>
>Just my $0.02.
>
>Cheers
>Tim.
>



To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message

Reply via email to