Tcl Source Code

View Ticket
Login
Ticket UUID: 1840814
Title: Error in ::ftp::Put
Type: Bug Version: obsolete: 8.4.12
Submitter: nobody Created on: 2007-11-29 09:10:49
Subsystem: 07. Variables Assigned To: msofer
Priority: 5 Medium Severity:
Status: Closed Last Modified: 2007-11-29 19:41:15
Resolution: Invalid Closed By: msofer
    Closed on: 2007-11-29 12:41:15
Description:
Hello,

I have some problems with the ftp package of the TCL library (version 1.8-1) by transferring (put and get) some test files from a host system to a test device (an embedded board with a Linux kernel). 

After the transfer of approx. 1700 files I got the following error:

[ ERROR ] 20071129_050202: err: can't read "ftp(Start_Time)": no such element in array

[ ERROR ] 20071129_050202: errorInfo: can't read "ftp(Start_Time)": no such element in array
    while executing
"expr {$stop_time - $ftp(Start_Time)}"
    (procedure "ElapsedTime" line 5)
    invoked from within
"ElapsedTime $s [clock seconds]"
    (procedure "::ftp::Put" line 87)
    invoked from within
"::ftp::Put $fd $file "
    (procedure "Ftp::Put" line 4)
    invoked from within
"Ftp::Put $ftpfd $testfile put_delta_ms "
    (procedure "linux_wlan::Start" line 92)
    invoked from within
"linux_wlan::Start --device=wlan0 --essid=dev_test_1 --count=100 --sizes=1M,2M,4M,8M --sleep=1 --dhcp --rates=1M,11M,24M,54M,auto --sysload --config-fi..."
    ("eval" body line 1)
    invoked from within
"eval [ subst { $testname $testargs } ] "


As you can see the error is coming from the ftp script, the procedure `::ftp::Put' seems the be the root of the problem.

About my script (see attachment): It opens a FTP session only one time, and then it starts with the transfers waiting 1 second before starting the next one.


The hardware/software components of my host system are:

- Linux 2.6.18-5-486 (Debian 4.0)
- Intel Pentium 4 (3.0GHz)
- Tcl: 8.4.12 (Tcllib 1.8-1)
- Ftp package version: 1.39 (2005/09/30)



Regards and thanks,


Luis Galdos
User Comments: msofer added on 2007-11-29 19:41:15:
Logged In: YES 
user_id=148712
Originator: NO

The problem seems to be that your $ftpd is not properly initialized at the time the linux_wlan script calls ::ftp::Put on it. 

This is a tcllib bug (as opposed to a Tcl bug): please submit to the correct tracker, and add info on how you are initializing $ftpd. The tracker is at http://sourceforge.net/projects/tcllib

[email protected] added on 2007-11-29 16:10:49:

File Added - 256564: linux_wlan.tcl

Attachments: