diff options
Diffstat (limited to 'ext/threads/threads.xs')
-rwxr-xr-x | ext/threads/threads.xs | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/ext/threads/threads.xs b/ext/threads/threads.xs index a4e22ec966..75a6b0b68f 100755 --- a/ext/threads/threads.xs +++ b/ext/threads/threads.xs @@ -111,6 +111,11 @@ SV* Perl_thread_create(char* class, SV* init_function, SV* params) { init_function = NULL; temp_store = NULL; + temp_store = Perl_get_sv(current_perl, "threads::origthread", TRUE | GV_ADDMULTI); + sv_setiv(temp_store,(IV)current_perl); + temp_store = NULL; + + #ifdef WIN32 thread->interp = perl_clone(current_perl, 4); #else @@ -122,6 +127,8 @@ SV* Perl_thread_create(char* class, SV* init_function, SV* params) { thread->params = newSVsv(Perl_get_sv(thread->interp, "threads::paramtempstore",FALSE)); + + /* * And here we make sure we clean up the data we put in the * namespace of iThread, both in the new and the calling |