This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
clean up compilation warnings
[perl5.git] / pp.c
diff --git a/pp.c b/pp.c
index 2ecdb87..c7d1841 100644 (file)
--- a/pp.c
+++ b/pp.c
@@ -650,10 +650,9 @@ PP(pp_gelem)
 PP(pp_study)
 {
     dVAR; dSP; dPOPss;
-    register unsigned char *s;
     STRLEN len;
 
-    s = (unsigned char*)(SvPV(sv, len));
+    len = SvCUR(sv);
     if (len == 0 || len > I32_MAX || !SvPOK(sv) || SvUTF8(sv) || SvVALID(sv)) {
        /* Historically, study was skipped in these cases. */
        RETPUSHNO;