Skip to content
Tcl Source Code History Of Ticket 406058ffffffffffffffffffffffffffffffffff
Login

History Of Ticket 406058ffffffffffffffffffffffffffffffffff

Artifacts Associated With Ticket 406058ffffffffffffffffffffffffffffffffff

  1. Ticket change [f58c09d0f6] (rid 130132) by villalba on 2001-03-05 17:21:49:

    1. assignee initialized to: "nobody"
    2. cmimetype initialized to: "text/plain"
    3. comment initialized to:
      working with Thread-2.1 under Windows-NT I found the  
      following bug. While executing
      
          for {set i 0} {$i < 1000} {incr i} { 
      set T [thread::create] 
      catch "thread::send $T thread::exit"
          }
      
      you can see in Task manager (of windows) that the  
      number of handles* grows up.
      
      * under processes in task manager choose columns in  
      View menu and mark number of handles.
      
      Greetings,
      Villalba
      
    4. foundin initialized to: "None"
    5. priority initialized to: "5 Medium"
    6. resolution initialized to: "None"
    7. status initialized to: "Open"
    8. submitter initialized to: "villalba"
    9. subsystem initialized to: "None"
    10. title initialized to: "Bug in thread library"
    11. type initialized to: "Bug"
  2. Ticket change [db16eed9cf] (rid 107901) by dkf on 2001-03-06 17:24:36:

    1. subsystem changed to: "49. Threading"
  3. Ticket change [6915fc5b70] (rid 103184) by davygrvy on 2001-04-26 04:36:58:

    1. icomment:
      Logged In: YES 
      user_id=7549
      
      change the catagory to the thread package, please.
      
      see https://sourceforge.net/tracker/index.php?
      func=detail&aid=418689&group_id=10894&atid=110894
      
      for a possible solution.
      
      
    2. login: "davygrvy"
    3. mimetype: "text/plain"
    4. username: "davygrvy"
  4. Ticket change [209e868f31] (rid 130456) by dgp on 2001-04-26 05:03:08:

    1. icomment:
      Logged In: YES 
      user_id=80530
      
      Changed category as requested.
      
      
    2. login: "dgp"
    3. mimetype: "text/plain"
    4. subsystem changed to: "80. Thread Package"
    5. username: "dgp"
  5. Ticket change [f3c8e3a2a5] (rid 129779) by dgp on 2001-04-26 05:24:01:

    1. assignee changed to: "davygrvy"
  6. Ticket change [f6b74d7e89] (rid 130341) by davygrvy on 2001-04-28 10:01:38:

    1. closedate changed to: "2001-04-28T03:01:38"
    2. closer changed to: "davygrvy"
    3. icomment:
      Logged In: YES 
      user_id=7549
      
      See https://sourceforge.net/tracker/index.php?
      func=detail&aid=419683&group_id=10894&atid=110894 for the 
      proposed fix.
      
      
    4. login: "davygrvy"
    5. mimetype: "text/plain"
    6. resolution changed to: "Duplicate"
    7. status changed to: "Closed"
    8. username: "davygrvy"
  7. Ticket change [6abbe2a6d1] (rid 128204) by villalba on 2001-05-10 20:50:11:

    1. closedate changed to: "2001-05-10T13:50:11"
    2. closer changed to: "villalba"
    3. icomment:
      Logged In: YES 
      user_id=166340
      
      It isn´t a problem of the thread library, but Tcl core. Pay 
      attention to the following easy example.
      
      #include <tcl.h>
      
      int ThreadMainProc( int& I ) 
      {
      I = 0;
      return 0;
      }
      
      int main( void )
      {
      int I = 1;
      Tcl_ThreadId* ThreadId = NULL;
      
      // At this point the number of handles is 14 and of 
      threads 1.
      
      if( Tcl_CreateThread(
      ThreadId, 
      (unsigned int (__stdcall *)(void 
      *)) ThreadMainProc,
      &I,
      TCL_THREAD_STACK_DEFAULT,
      TCL_THREAD_NOFLAGS ) != TCL_OK)
      {
      return 1;// Error handle
      }
      
      // This loop is finished by the thread.
      // At this point the number of handles is 15 and of 
      threads 2.
      while( I )
      printf( "%d", I );
      
      // At this point the number of handles is 15 and of 
      threads 1, i.e. the thread is dead.
      
      return 0;
      }
      
      
      
      
    4. login: "villalba"
    5. mimetype: "text/plain"
    6. username: "villalba"
  8. Ticket change [8bc3c887f1] (rid 127634) by davygrvy on 2001-05-11 02:11:31:

    1. icomment:
      Logged In: YES 
      user_id=7549
      
      See http://sourceforge.net/tracker/?
      func=detail&atid=110894&aid=419683&group_id=10894
      
      for the patch that fixes your problem as was stated before.
      
      
    2. login: "davygrvy"
    3. mimetype: "text/plain"
    4. username: "davygrvy"
  9. Ticket change [061efb93e2] (rid 89165) by nobody on 2001-05-11 05:18:42:

    1. icomment:
      
      
      File Added - 6187: test1.c
      
      
      
    2. login: "nobody"
    3. mimetype: "text/plain"
    4. username: "nobody"
  10. Add attachment "test1.c" [ba6121aeff] (rid 129316) by nobody on 2001-05-11 05:18:42.

  11. Ticket change [a92bdf6d97] (rid 99112) by davygrvy on 2001-05-11 05:22:05:

    1. closedate changed to: "2001-05-10T22:22:05"
    2. closer changed to: "davygrvy"
    3. icomment:
      Logged In: YES 
      user_id=7549
      
      Under deeper inspection of your code, I'd like to edit it 
      for better cross-platform support of the threading macros 
      in tcl.h.  Honestly, casting of function types is evil.  
      Especially the calling convention part.  I don't think I'm 
      being nit-picky because the compiler will emit different 
      different machine code for __cdecl and __stdcall.  Try it 
      and look at the difference of the stack handling of the 
      listing .asm file.  There's no handle leak present with the 
      patch from 419683 applied.
      
      
      
    4. login: "davygrvy"
    5. mimetype: "text/plain"
    6. username: "davygrvy"
  12. Ticket change [c9fa811f46] (rid 122382) by villalba on 2001-05-11 21:22:04:

    1. closedate changed to: "2001-05-11T14:22:04"
    2. closer changed to: "villalba"
    3. icomment:
      Logged In: YES 
      user_id=166340
      
      I´ve tried the patch http://sourceforge.net/tracker/?
      func=detail&atid=110894&aid=419683&group_id=10894 but it 
      isn´t successful.
      
      
    4. login: "villalba"
    5. mimetype: "text/plain"
    6. username: "villalba"
  13. Ticket change [c7e1bfc03f] (rid 122017) by davygrvy on 2001-05-12 05:40:54:

    1. closedate changed to: "2001-05-11T22:40:54"
    2. closer changed to: "davygrvy"
    3. icomment:
      Logged In: YES 
      user_id=7549
      
      All I can say is that it worked for me and dropping the 
      handle reference in Tcl_CreateThread did cause the app's 
      handle count to decrement when the thread closed.
      
      If you have any other ideas for a fix, let me know.
      
      
    4. login: "davygrvy"
    5. mimetype: "text/plain"
    6. username: "davygrvy"
  14. Ticket change [5a3ed94bb9] (rid 118108) by davygrvy on 2001-05-12 06:24:44:

    1. status changed to: "Open"
  15. Ticket change [6b17397e2b] (rid 128254) by davygrvy on 2001-05-12 06:28:51:

    1. icomment:
      Logged In: YES 
      user_id=7549
      
      I should have said, "never caused the app's handle count to 
      increment at all."
      
      
    2. login: "davygrvy"
    3. mimetype: "text/plain"
    4. username: "davygrvy"
  16. Ticket change [e4a51244f3] (rid 87987) by davygrvy on 2001-05-27 10:22:40:

    1. closedate changed to: "2001-05-27T03:22:40"
    2. closer changed to: "davygrvy"
    3. status changed to: "Closed"