summaryrefslogtreecommitdiff
path: root/scope.c
diff options
context:
space:
mode:
authorSteve Peters <steve@fisharerojo.org>2005-05-31 04:55:43 -0500
committerAbhijit Menon-Sen <ams@wiw.org>2005-06-02 08:44:41 +0000
commitaa07b2f68da542daf881aa4d73a68f7bc8c114b1 (patch)
tree6f49d4e76f116fa1a0cd5785508a86e18b967230 /scope.c
parent616d8c9c7dee8ffe0d25891708d3380cabc2db84 (diff)
downloadperl-aa07b2f68da542daf881aa4d73a68f7bc8c114b1.tar.gz
SvPVX_const() - part 3 ... and const'ing Storable
Message-Id: <20050531145543.GA8051@mccoy.peters.homeunix.org> p4raw-id: //depot/perl@24670
Diffstat (limited to 'scope.c')
-rw-r--r--scope.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/scope.c b/scope.c
index 5fce68a83a..494fe0bf70 100644
--- a/scope.c
+++ b/scope.c
@@ -267,7 +267,7 @@ Perl_save_gp(pTHX_ GV *gv, I32 empty)
SSPUSHIV((IV)SvLEN(gv));
SvLEN_set(gv, 0); /* forget that anything was allocated here */
SSPUSHIV((IV)SvCUR(gv));
- SSPUSHPTR(SvPVX(gv));
+ SSPUSHPTR(SvPVX_const(gv));
SvPOK_off(gv);
SSPUSHPTR(SvREFCNT_inc(gv));
SSPUSHPTR(GvGP(gv));
@@ -838,8 +838,8 @@ Perl_leave_scope(pTHX_ I32 base)
case SAVEt_GP: /* scalar reference */
ptr = SSPOPPTR;
gv = (GV*)SSPOPPTR;
- if (SvPVX(gv) && SvLEN(gv) > 0) {
- Safefree(SvPVX(gv));
+ if (SvPVX_const(gv) && SvLEN(gv) > 0) {
+ Safefree(SvPVX_const(gv));
}
SvPV_set(gv, (char *)SSPOPPTR);
SvCUR_set(gv, (STRLEN)SSPOPIV);
@@ -1091,7 +1091,7 @@ Perl_cx_dump(pTHX_ PERL_CONTEXT *cx)
PL_op_desc[cx->blk_eval.old_op_type]);
if (cx->blk_eval.old_namesv)
PerlIO_printf(Perl_debug_log, "BLK_EVAL.OLD_NAME = %s\n",
- SvPVX(cx->blk_eval.old_namesv));
+ SvPVX_const(cx->blk_eval.old_namesv));
PerlIO_printf(Perl_debug_log, "BLK_EVAL.OLD_EVAL_ROOT = 0x%"UVxf"\n",
PTR2UV(cx->blk_eval.old_eval_root));
PerlIO_printf(Perl_debug_log, "BLK_EVAL.RETOP = 0x%"UVxf"\n",