In attrs::get(), use Perl_get_cvn_flags() rather than perl_get_cv().
Nicholas Clark [Wed, 21 Jan 2009 16:12:06 +0000 (16:12 +0000)]
ext/attrs/attrs.xs

index e3ba012..c7fce19 100644 (file)
@@ -52,8 +52,9 @@ SV *  sub
                sub = Nullsv;
        }
        else {
-           const char * const name = SvPV_nolen(sub);
-           sub = (SV*)perl_get_cv(name, FALSE);
+           STRLEN len;
+           const char * const name = SvPV(sub, len);
+           sub = (SV*)get_cvn_flags(name, len, SvUTF8(sub));
        }
        if (!sub)
            croak("invalid subroutine reference or name");