diff options
author | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2014-03-17 15:03:22 +0100 |
---|---|---|
committer | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2014-03-31 08:29:43 +0200 |
commit | 391ad3ee4ff868c637a4e1c254da96f194be04e4 (patch) | |
tree | 1016e0ddcc317aa892476ff0e47acb6beb6edd0c /cpukit/posix/src/pthread.c | |
parent | score: Reduce _Thread_Reset() parameters (diff) | |
download | rtems-391ad3ee4ff868c637a4e1c254da96f194be04e4.tar.bz2 |
score: Fix thread restart extensions context
Run the thread restart extensions in the context of the restarted
thread. Run them with thread dispatching enabled.
Diffstat (limited to 'cpukit/posix/src/pthread.c')
-rw-r--r-- | cpukit/posix/src/pthread.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/cpukit/posix/src/pthread.c b/cpukit/posix/src/pthread.c index d2e637365e..0416e28adf 100644 --- a/cpukit/posix/src/pthread.c +++ b/cpukit/posix/src/pthread.c @@ -255,6 +255,15 @@ static bool _POSIX_Threads_Create_extension( return true; } +static void _POSIX_Threads_Restart_extension( + Thread_Control *executing, + Thread_Control *restarted +) +{ + (void) executing; + _POSIX_Threads_cancel_run( restarted ); +} + /* * _POSIX_Threads_Delete_extension * @@ -336,7 +345,7 @@ User_extensions_Control _POSIX_Threads_User_extensions = { { { NULL, NULL }, NULL }, { _POSIX_Threads_Create_extension, /* create */ NULL, /* start */ - NULL, /* restart */ + _POSIX_Threads_Restart_extension, /* restart */ _POSIX_Threads_Delete_extension, /* delete */ NULL, /* switch */ NULL, /* begin */ |