summaryrefslogtreecommitdiff
path: root/ext/Devel-Peek/Peek.xs
diff options
context:
space:
mode:
Diffstat (limited to 'ext/Devel-Peek/Peek.xs')
-rw-r--r--ext/Devel-Peek/Peek.xs1
1 files changed, 1 insertions, 0 deletions
diff --git a/ext/Devel-Peek/Peek.xs b/ext/Devel-Peek/Peek.xs
index 3dcba4780e..5e8deb9830 100644
--- a/ext/Devel-Peek/Peek.xs
+++ b/ext/Devel-Peek/Peek.xs
@@ -161,6 +161,7 @@ fill_mstats(SV *sv, int level)
{
dTHX;
+ if (SvIsCOW(sv)) sv_force_normal(sv);
if (SvREADONLY(sv))
croak("Cannot modify a readonly value");
SvGROW(sv, sizeof(struct mstats_buffer)+1);