ftpd::Session method RETR (protected)

 <instance of ftpd::Session[i]> RETR arg

Defined in

Parameters:
arg (required)

Testcases:
No testcase defined.
Source code:
:require_data $arg {
    set filename $arg
    if {[:file exists $filename]} {
        :reply "150 Opening data connection for returning data."
        set F [:file open $filename r]; set data [read $F]; close $F
        :write_data $data
        :reply "226 Transfer complete."
    } else {
        :reply "550 File not found."
    }
    :close_data
}
XQL Not present:
Generic, PostgreSQL, Oracle
[ hide source ] | [ make this the default ]
Show another procedure: