summaryrefslogtreecommitdiff
path: root/doop.c
diff options
context:
space:
mode:
Diffstat (limited to 'doop.c')
-rw-r--r--doop.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/doop.c b/doop.c
index d7ab071e84..98876d3fe6 100644
--- a/doop.c
+++ b/doop.c
@@ -605,7 +605,7 @@ Perl_do_trans(pTHX_ SV *sv)
if (SvREADONLY(sv) && !(PL_op->op_private & OPpTRANS_IDENTICAL))
Perl_croak(aTHX_ PL_no_modify);
}
- (void)SvPV(sv, len);
+ (void)SvPV_const(sv, len);
if (!len)
return 0;
if (!(PL_op->op_private & OPpTRANS_IDENTICAL)) {
@@ -717,7 +717,7 @@ UV
Perl_do_vecget(pTHX_ SV *sv, I32 offset, I32 size)
{
STRLEN srclen, len;
- unsigned char *s = (unsigned char *) SvPV(sv, srclen);
+ const unsigned char *s = (const unsigned char *) SvPV_const(sv, srclen);
UV retnum = 0;
if (offset < 0)