s |I32 |expect_number |char** pattern
#
# if defined(USE_ITHREADS)
-s |SV* |gv_share |SV *sv
+s |SV* |gv_share |SV *sv|CLONE_PARAMS *param
# endif
#endif
# endif
#define expect_number(a) S_expect_number(aTHX_ a)
# if defined(USE_ITHREADS)
-#define gv_share(a) S_gv_share(aTHX_ a)
+#define gv_share(a,b) S_gv_share(aTHX_ a,b)
# endif
#endif
#if defined(PERL_IN_TOKE_C) || defined(PERL_DECL_PROT)
STATIC I32 S_expect_number(pTHX_ char** pattern);
#
# if defined(USE_ITHREADS)
-STATIC SV* S_gv_share(pTHX_ SV *sv);
+STATIC SV* S_gv_share(pTHX_ SV *sv, CLONE_PARAMS *param);
# endif
#endif
/* attempt to make everything in the typeglob readonly */
STATIC SV *
-S_gv_share(pTHX_ SV *sstr)
+S_gv_share(pTHX_ SV *sstr, CLONE_PARAMS *param)
{
GV *gv = (GV*)sstr;
- SV *sv = &PL_sv_no; /* just need SvREADONLY-ness */
+ SV *sv = ¶m->proto_perl->Isv_no; /* just need SvREADONLY-ness */
if (GvIO(gv) || GvFORM(gv)) {
GvUNIQUE_off(gv); /* GvIOs cannot be shared. nor can GvFORMs */
case SVt_PVGV:
if (GvUNIQUE((GV*)sstr)) {
SV *share;
- if ((share = gv_share(sstr))) {
+ if ((share = gv_share(sstr, param))) {
del_SV(dstr);
dstr = share;
ptr_table_store(PL_ptr_table, sstr, dstr);
# endif /* DEBUGGING */
#endif /* PERL_IMPLICIT_SYS */
param->flags = flags;
+ param->proto_perl = proto_perl;
/* arena roots */
PL_xiv_arenaroot = NULL;