View Single Post
Old 01-04-2003, 03:30 PM  
tuff
Senior Member
 
Join Date: Jan 2003
Posts: 277
Exclamation Serious Bug? 3.9.1 with events and returning?

i`m attempting to use the [pre] event with stor to process
a file which is about to be uploaded ie. test.rar

[pre]
stor = c:\ioFTPD\ioSFV\ioSFV.itcl

$args now contains `STOR test.rar` (without the `s)

basically i`m comparing $args to catch the STOR
(if {[string match "STOR" [lindex $args 0]]} {......)

now, if you try and return from this routine you`ll get various problems:

return (will stall the client until you manually abort)
}

break (will stall the client until you manually abort)
}

exit (will kill the ftpd completely, needs restarted)
}

using `return` with various args, ie. 0, 1 etc etc has no effect

this will only happen when ioerror is set to something other than 0 ie.

set ioerror 1

i know i can make this as a standalone script, and it will work
without the need for a `return` at all, but id like to keep all
the processes the sfv checker will use in 1 itcl.
tuff is offline   Reply With Quote