Skip to content
Tcl Source Code View Ticket
Login

View Ticket

2001-04-06
02:42 • Ticket [218270ffff] test failure: can this be ignored ? status still Closed ... artifact: 065299437f user: dgp
2000-10-26
08:17 • Closed ticket [218270ffff]. artifact: 11c5557691 user: welch
00:55 • New ticket [218270ffff]. artifact: d7e4dffc63 user: nobody

test failure: can this be ignored ?

Closed / Fixed218270ffffffffffffffffffffffffffffffffffCreated 26 years agoUpdated 26 years ago
Descriptionplain2000-10-26 00:55:17
OriginalBugID: 3346 Bug
Version: 8.2.1
SubmitDate: '1999-11-05'
LastModified: '2000-01-11'
Severity: SER
Status: Closed
Submitter: techsupp
ChangedBy: hobbs
OS: IRIX
OSVersion: IRIX64 6.5.5.
FixedDate: '2000-10-25'
ClosedDate: '2000-01-11'


Name:
Nils H. Busch

Extensions:
none

ReproducibleScript:
C compiler used SGI cc v. 7.3
    configure 
    make test

ObservedBehavior:
configure error:
    configure:2436: cc -c   conftest.c 1>&5
    cc-1565 cc: ERROR File = configure, Line = 2432
      The struct "tm" has no field "tm_gmtoff".
    
      struct tm tm; tm.tm_gmtoff;
                       ^
    
    1 error detected in the compilation of "conftest.c".
    configure: failed program was:
    #line 2429 "configure"
    #include "confdefs.h"
    #include <time.h>
    int main() {
    struct tm tm; tm.tm_gmtoff;
    ; return 0; }
    
    error in test:
    socket.test
    
    ==== socket-2.3 tcp connection with client interface specified FAILED
    ==== Contents of test case:
    
        removeFile script
        set f [open script w]
        puts $f {
            set timer [after 2000 "set x done"]
            set f [socket  -server accept 2830]
            proc accept {file addr port} {
                global x
                puts "[gets $file] $addr"
                close $file
                set x done
            }
            puts ready
            vwait x
            after cancel $timer
            close $f
        }
        close $f
        set f [open "|[list $::tcltest::tcltest script]" r]
        gets $f x
        if {[catch {socket -myaddr 127.0.0.1 127.0.0.1 2830} sock]} {
            set x $sock
        } else {
            puts $sock hello
            flush $sock
            lappend x [gets $f]
            close $sock
        }
        close $f
        set x
    
    ---- Result was:
    ready {hello 0.0.0.0}
    ---- Result should have been:
    ready {hello 127.0.0.1}
    ==== socket-2.3 FAILED
    
    ==== socket-7.1 testing socket specific options FAILED
    ==== Contents of test case:
    
        removeFile script
        set f [open script w]
        puts $f {
            socket -server accept 2820
            proc accept args {
                global x
                set x done
            }
            puts ready
            set timer [after 10000 "set x timed_out"]
            vwait x
            after cancel $timer
        }
        close $f
        set f [open "|[list $::tcltest::tcltest script]" r]
        gets $f
        set s [socket 127.0.0.1 2820]
        set p [fconfigure $s -peername]
        close $s
        close $f
        set l ""
        lappend l [string compare [lindex $p 0] 127.0.0.1]
        lappend l [string compare [lindex $p 2] 2820]
        lappend l [llength $p]
    
    ---- Result was:
    -1 0 3
    ---- Result should have been:
    0 0 3
    ==== socket-7.1 FAILED
    
    ==== socket-7.2 testing socket specific options FAILED
    ==== Contents of test case:
    
        removeFile script
        set f [open script w]
        puts $f {
            socket -server accept 2821
            proc accept args {
                global x
                set x done
            }
            puts ready
            set timer [after 10000 "set x timed_out"]
            vwait x
            after cancel $timer
        }
        close $f
        set f [open "|[list $::tcltest::tcltest script]" r]
        gets $f
        set s [socket 127.0.0.1 2821]
        set p [fconfigure $s -sockname]
        close $s
        close $f
        set l ""
        lappend l [llength $p]
        lappend l [lindex $p 0]
        lappend l [expr [lindex $p 2] == 2821]
    
    ---- Result was:
    3 0.0.0.0 0
    ---- Result should have been:
    3 127.0.0.1 0
    ==== socket-7.2 FAILED
    
    ==== socket-7.5 testing socket specific options FAILED
    ==== Contents of test case:
    
        set s [socket -server accept 2829]
        proc accept {s a p} {
            global x
            set x [fconfigure $s -sockname]
            close $s
        }
        set s1 [socket 127.0.0.1 2829]
        set timer [after 10000 "set x timed_out"]
        vwait x
        after cancel $timer
        close $s
        close $s1
        set l ""
        lappend l [lindex $x 0] [lindex $x 2] [llength $x]
    
    ---- Result was:
    0.0.0.0 2829 3
    ---- Result should have been:
    127.0.0.1 2829 3
    ==== socket-7.5 FAILED

DesiredBehavior:
no error in configure
    successfully completetd tests



These are not to be worried about.  The configure "failure" is
intentional, to see if that code would work at all.  It will
cause a -D def that will make the code work as expected.

The socket problems are all related to the fact that 0.0.0.0
was returned instead of the normal loopback 127.0.0.1.  This
is just a system config issue, where the tests are expecting
the standard loopback (they aren't all that flexible), and
it won't affect the operation of Tcl, including sockets. 
-- 01/11/2000 hobbs
welch Closed ticket [218270ffff]. [History diff]2000-10-26 08:17:57
dgp Ticket [218270ffff]: 3 changes [History diff]2001-04-06 02:42:18
Log in (anonymous is fine) to add a comment.