cvsuser     04/03/31 03:55:43

  Modified:    include/parrot thread.h
               src      thread.c
  Log:
  set a flag for not yet running threads
  
  Revision  Changes    Path
  1.20      +3 -2      parrot/include/parrot/thread.h
  
  Index: thread.h
  ===================================================================
  RCS file: /cvs/public/parrot/include/parrot/thread.h,v
  retrieving revision 1.19
  retrieving revision 1.20
  diff -u -w -r1.19 -r1.20
  --- thread.h  27 Jan 2004 09:57:47 -0000      1.19
  +++ thread.h  31 Mar 2004 11:55:34 -0000      1.20
  @@ -1,7 +1,7 @@
   /* thread.h
    *  Copyright: 2001-2003 The Perl Foundation.  All Rights Reserved.
    *  CVS Info
  - *     $Id: thread.h,v 1.19 2004/01/27 09:57:47 leo Exp $
  + *     $Id: thread.h,v 1.20 2004/03/31 11:55:34 leo Exp $
    *  Overview:
    *     This is the api header for the thread primitives
    *  Data Structure and Algorithms:
  @@ -68,7 +68,8 @@
       THREAD_STATE_JOINABLE,              /* default */
       THREAD_STATE_DETACHED = 0x01,       /* i.e. non-joinable */
       THREAD_STATE_JOINED   = 0x02,       /* JOIN was issued */
  -    THREAD_STATE_FINISHED = 0x04        /* the thread function has ended */
  +    THREAD_STATE_FINISHED = 0x04,        /* the thread function has ended */
  +    THREAD_STATE_NOT_STARTED = 0x08      /* the thread wasn't started */
   } thread_state_enum;
   
   /*
  
  
  
  1.25      +3 -1      parrot/src/thread.c
  
  Index: thread.c
  ===================================================================
  RCS file: /cvs/public/parrot/src/thread.c,v
  retrieving revision 1.24
  retrieving revision 1.25
  diff -u -w -r1.24 -r1.25
  --- thread.c  30 Mar 2004 10:23:25 -0000      1.24
  +++ thread.c  31 Mar 2004 11:55:43 -0000      1.25
  @@ -1,6 +1,6 @@
   /*
   Copyright: 2001-2003 The Perl Foundation.  All Rights Reserved.
  -$Id: thread.c,v 1.24 2004/03/30 10:23:25 leo Exp $
  +$Id: thread.c,v 1.25 2004/03/31 11:55:43 leo Exp $
   
   =head1 NAME
   
  @@ -573,6 +573,7 @@
           if (interpreter_array[i] == NULL) {
               interpreter_array[i] = new_interp;
               new_interp->thread_data->tid = i;
  +            new_interp->thread_data->state = THREAD_STATE_NOT_STARTED;
               return;
           }
       }
  @@ -583,6 +584,7 @@
               (n_interpreters + 1) * sizeof(Parrot_Interp));
       interpreter_array[n_interpreters] = new_interp;
       new_interp->thread_data->tid = n_interpreters;
  +    new_interp->thread_data->state = THREAD_STATE_NOT_STARTED;
       ++n_interpreters;
   }
   
  
  
  

Reply via email to