dougm 00/04/20 22:16:53
Modified: patches perl_no_get_context.pat
Log:
more 5.6.0 brokenness
Revision Changes Path
1.2 +40 -0 modperl-2.0/patches/perl_no_get_context.pat
Index: perl_no_get_context.pat
===================================================================
RCS file: /home/cvs/modperl-2.0/patches/perl_no_get_context.pat,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- perl_no_get_context.pat 2000/04/16 16:53:03 1.1
+++ perl_no_get_context.pat 2000/04/21 05:16:53 1.2
@@ -27,3 +27,43 @@
SV * version_sv = perl_get_sv("DB_File::db_version", GV_ADD|GV_ADDMULTI) ;
SV * ver_sv = perl_get_sv("DB_File::db_ver", GV_ADD|GV_ADDMULTI) ;
SV * compat_sv = perl_get_sv("DB_File::db_185_compat", GV_ADD|GV_ADDMULTI) ;
+--- thread.h~ Sat Mar 11 08:42:45 2000
++++ thread.h Thu Apr 20 17:38:17 2000
+@@ -229,18 +229,6 @@
+ } STMT_END
+ #endif /* JOIN */
+
+-#ifndef PERL_GET_CONTEXT
+-# define PERL_GET_CONTEXT pthread_getspecific(PL_thr_key)
+-#endif
+-
+-#ifndef PERL_SET_CONTEXT
+-# define PERL_SET_CONTEXT(t) \
+- STMT_START { \
+- if (pthread_setspecific(PL_thr_key, (void *)(t))) \
+- Perl_croak_nocontext("panic: pthread_setspecific"); \
+- } STMT_END
+-#endif /* PERL_SET_CONTEXT */
+-
+ #ifndef INIT_THREADS
+ # ifdef NEED_PTHREAD_INIT
+ # define INIT_THREADS pthread_init()
+@@ -263,6 +251,18 @@
+ #endif /* THREAD_RET */
+
+ #if defined(USE_THREADS)
++
++#ifndef PERL_GET_CONTEXT
++# define PERL_GET_CONTEXT pthread_getspecific(PL_thr_key)
++#endif
++
++#ifndef PERL_SET_CONTEXT
++# define PERL_SET_CONTEXT(t) \
++ STMT_START { \
++ if (pthread_setspecific(PL_thr_key, (void *)(t))) \
++ Perl_croak_nocontext("panic: pthread_setspecific"); \
++ } STMT_END
++#endif /* PERL_SET_CONTEXT */
+
+ /* Accessor for per-thread SVs */
+ # define THREADSV(i) (thr->threadsvp[i])