Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: 37aad3b747f9851e3e21c2e136c496155ce37b17
Ticket: 3161787fffffffffffffffffffffffffffffffff
Unhandled exception with threaded itcl objects
User & Date: sebres on 2012-04-10 21:44:02
Changes

  1. icomment:
    reproduced with WinXP, thread2.7, thread2.6.7, Itcl3.4
    seems to be Itcl bug (cause the same with namespace does not produce exception) :
    
    >>> SUCCESS >>>
    package re Thread
    ## init ------
    set ::tid [thread::create {
      #proc _out_err {args} {puts $args}; 
      #thread::errorproc _out_err;
      thread::wait
    }]
    ## crash ------
    proc thread_procCrash {args} {
      thread::send -async $::tid {testnamespace::unkowncommand}
    }
    ## do test ------
    proc dotest {} {
      thread::send -async $::tid {namespace eval testnamespace {}}
      for {set index 0} {$index < 100000} {incr index} {thread_procCrash}
    }
    ## do test ------
    dotest
    <<< <<<
    
    >>> BOOM >>>
    package re Thread
    ## init ------
    set ::tid [thread::create {
      #proc _out_err {args} {puts $args}; 
      #thread::errorproc _out_err;
      thread::wait
    }]
    ## crash ------
    proc thread_procCrash {args} {
      thread::send -async $::tid {testObj unkowncommand}
    }
    ## do test ------
    proc dotest {} {
      thread::send -async $::tid {
        package require Itcl
        itcl::class TestClass {}
        TestClass testObj
      }
      for {set index 0} {$index < 100000} {incr index} {thread_procCrash}
    }
    ## do test ------
    dotest
    <<< <<<
    
    
  2. login: "sebres"
  3. mimetype: "text/plain"
  4. username: "sebres"