summaryrefslogtreecommitdiffstats
path: root/tcllib/examples/ftpd/ftpd.unix
blob: 03ef9269928c47fb5043cce773e65d5fc2a4282e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
#!/usr/bin/env tclsh
## -*- tcl -*-
# FTP daemon

package require Tcl 8.3
if {[catch {package require ftpd}]} {
    set here [file dirname [info script]]
    source [file join .. $here ftpd.tcl]
}

proc bgerror {args} {
    global errorInfo
    puts stderr "bgerror: [join $args]"
    puts stderr $errorInfo
}

::ftpd::config -authUsrCmd ::ftpd::unixAuth
::ftpd::server
vwait forever