TAINT_NOT;
sv_setpvn(sv, s, i);
PL_tainted = oldtainted;
- if ( (rx->reganch & ROPT_CANY_SEEN)
+ if ( (rx->extflags & RXf_CANY_SEEN)
? (RX_MATCH_UTF8(rx)
&& (!i || is_utf8_string((U8*)s, i)))
: (RX_MATCH_UTF8(rx)) )
SvREFCNT_dec(to_dec);
return 0;
}
- s = SvOK(sv) ? SvPV_force(sv,len) : "IGNORE";
+ s = SvOK(sv) ? SvPV_force(sv,len) : "DEFAULT";
if (strEQ(s,"IGNORE")) {
if (i) {
#ifdef FAKE_PERSISTENT_SIGNAL_HANDLERS
setproctitle("%s", s);
# endif
}
-#endif
-#if defined(__hpux) && defined(PSTAT_SETCMD)
+#elif defined(__hpux) && defined(PSTAT_SETCMD)
if (PL_origalen != 1) {
union pstun un;
s = SvPV_const(sv, len);
un.pst_command = (char *)s;
pstat(PSTAT_SETCMD, un, len, 0, 0);
}
-#endif
+#else
if (PL_origalen > 1) {
/* PL_origalen is set in perl_parse(). */
s = SvPV_force(sv,len);
Copy(s, PL_origargv[0], len, char);
PL_origargv[0][len] = 0;
memset(PL_origargv[0] + len + 1,
+#ifdef PERL_DARWIN
+ /* Special case for darwin: see [perl #38868] */
+ (int)'\0',
+#else
/* Is the space counterintuitive? Yes.
- * (You were expecting \0?)
+ * (You were expecting \0?)
* Does it work? Seems to. (In Linux 2.4.20 at least.)
* --jhi */
(int)' ',
+#endif
PL_origalen - len - 1);
}
PL_origargv[0][PL_origalen-1] = 0;
for (i = 1; i < PL_origargc; i++)
PL_origargv[i] = 0;
}
+#endif
UNLOCK_DOLLARZERO_MUTEX;
break;
#endif