cURL / Mailing Lists / curl-library / Single Mail

curl-library

FTP adjustments for curl from/to VMS

From: Daniel Stenberg <daniel_at_haxx.se>
Date: Fri, 8 Apr 2005 23:50:22 +0200 (CEST)

On Fri, 8 Apr 2005 marty_at_kuhrt.net wrote:

(This is a reply in a discussion Marty Kuhrt and I have been doing privately,
that is now moved over to the list. The topic is about fixing libcurl's FTP
support to do better on VMS. Like KNOWN_BUGS #22. This would be made by using
the STRU command properly.)

>> At what point in the FTP command sequence do you want to add the STRU
>> command? It is only for upload from a VMS host, right?
>
> It should work with any ftp server that supports the STRU O VMS command.
> It only makes sense if the sender or receiver (or both) is VMS because most
> other OSs don't have all these different file types built in.

Right. But since we don't know if the receiver is a VMS server, we have a few
choices:

1) Always send it and check the response code and act accordingly. This will
    add an extra round-trip for all FTP transfers. (And will force us to edit
    lots of test cases.)

2) Offer an option and only send it conditionally, with the effect that people
    won't notice this and get problems with VMS servers

3) Use other means of figuring it out. Like the SYST command. But that would
    add a command to all transfers anyway and make *two* new commands for VMS
    transfers.

>> I guess the STRU usage only makse sense to get used when build for VMS?
>
> STRU is in RFC959 in section 3.1.2 right after TYPE, in section 3.1.1 (at
> least in http://www.faqs.org/rfcs/rfc959.html). By default STRU defaults to
> F, for file. By that RFC is looks like only F(ile), R(ecord) and P(age) are
> supported. A STRU O VMS command essentially translates into a TYPE, STRU
> and MODE command that ends up like so; "Type: Ascii (Non-Print), Structure:
> VMS, Mode: Stream".
>
> So I guess the STRU command should be supported, regardless of VMSisms
> invoked with the STRU O VMS non-RFC variant.

-- 
          -=- Daniel Stenberg -=- http://daniel.haxx.se -=-
   ech`echo xiun|tr nu oc|sed 'sx\([sx]\)\([xoi]\)xo un\2\1 is xg'`ol
Received on 2005-04-09