Sync with libnet 1.16
[p5sagit/p5-mst-13.2.git] / pp_ctl.c
index f726ab7..42fea59 100644 (file)
--- a/pp_ctl.c
+++ b/pp_ctl.c
@@ -1365,8 +1365,6 @@ Perl_die_where(pTHX_ char *message, STRLEN msglen)
                sv_setpvn(ERRSV, message, msglen);
            }
        }
-       else
-           message = SvPVx(ERRSV, msglen);
 
        while ((cxix = dopoptoeval(cxstack_ix)) < 0
               && PL_curstackinfo->si_prev)
@@ -1383,6 +1381,8 @@ Perl_die_where(pTHX_ char *message, STRLEN msglen)
 
            POPBLOCK(cx,PL_curpm);
            if (CxTYPE(cx) != CXt_EVAL) {
+               if (!message)
+                   message = SvPVx(ERRSV, msglen);
                PerlIO_write(Perl_error_log, "panic: die ", 11);
                PerlIO_write(Perl_error_log, message, msglen);
                my_exit(1);
@@ -2898,13 +2898,7 @@ S_doeval(pTHX_ int gimme, OP** startop, CV* outside, U32 seq)
        *startop = PL_eval_root;
     } else
        SAVEFREEOP(PL_eval_root);
-    if (gimme & G_VOID && ! PL_in_eval & EVAL_INREQUIRE)
-       /*
-        * EVAL_INREQUIRE (the code is being required) is special-cased :
-        * in this case we want scalar context to be forced, instead
-        * of void context, so a proper return value is returned from
-        * C<require> via this leaveeval op.
-        */
+    if (gimme & G_VOID)
        scalarvoid(PL_eval_root);
     else if (gimme & G_ARRAY)
        list(PL_eval_root);