projects
/
model-checker.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
edf8e50
)
libthreads: make typedef for 'thread_id_t'
author
Brian Norris
<banorris@uci.edu>
Thu, 15 Mar 2012 22:42:36 +0000
(15:42 -0700)
committer
Brian Norris
<banorris@uci.edu>
Thu, 5 Apr 2012 17:05:44 +0000
(10:05 -0700)
Just in case we need to change it later on, let's use it as a named type.
libthreads.h
patch
|
blob
|
history
diff --git
a/libthreads.h
b/libthreads.h
index aa7faf44d255452c172e2db2cf40919e4453b555..9d290a7ddf12162ce67fa2a20294da4e4034cfb8 100644
(file)
--- a/
libthreads.h
+++ b/
libthreads.h
@@
-10,12
+10,14
@@
typedef enum thread_state {
THREAD_COMPLETED
} thread_state;
+typedef int thread_id_t;
+
struct thread {
void (*start_routine)();
void *arg;
ucontext_t context;
void *stack;
-
in
t id;
+
thread_id_
t id;
thread_state state;
};