summaryrefslogtreecommitdiff
path: root/pp.c
diff options
context:
space:
mode:
authorFather Chrysostomos <sprout@cpan.org>2012-06-27 12:41:56 -0700
committerFather Chrysostomos <sprout@cpan.org>2012-06-27 12:41:56 -0700
commit1fa930f22a3485f9bb86d555541c3ac82dc767b6 (patch)
tree388e58068296d4a51cb26e5b37048ec5f93f4558 /pp.c
parent4f8dbb2da2038925c8238010259dcd81d79d7368 (diff)
downloadperl-1fa930f22a3485f9bb86d555541c3ac82dc767b6.tar.gz
pp.c: Restore uninit warning to study
Also, prevent a crash when SvCUR is used on a non-PV.
Diffstat (limited to 'pp.c')
-rw-r--r--pp.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/pp.c b/pp.c
index c7d1841d61..1742baa2cb 100644
--- a/pp.c
+++ b/pp.c
@@ -652,7 +652,7 @@ PP(pp_study)
dVAR; dSP; dPOPss;
STRLEN len;
- len = SvCUR(sv);
+ (void)SvPV(sv, len);
if (len == 0 || len > I32_MAX || !SvPOK(sv) || SvUTF8(sv) || SvVALID(sv)) {
/* Historically, study was skipped in these cases. */
RETPUSHNO;