]> git.vpit.fr Git - perl/modules/Variable-Magic.git/commitdiff
Turn READONLY on onto wizard objects
authorVincent Pit <vince@profvince.com>
Sat, 20 Sep 2008 09:10:08 +0000 (11:10 +0200)
committerVincent Pit <vince@profvince.com>
Sat, 20 Sep 2008 09:10:08 +0000 (11:10 +0200)
Magic.xs

index 89df570ec4d896ae54599ad0408221dccbcb1a64..5e76f8a73b25bdc688950214d81cf256b71c7f90 100644 (file)
--- a/Magic.xs
+++ b/Magic.xs
@@ -834,6 +834,7 @@ CODE:
  sv = MGWIZ2SV(w);
  mg = sv_magicext(sv, NULL, PERL_MAGIC_ext, &vmg_wizard_vtbl, NULL, -1);
  mg->mg_private = SIG_WIZ;
+ SvREADONLY_on(sv);
 
  hv_store(MY_CXT.wizz, buf, sprintf(buf, "%u", sig), sv, 0);
  ++MY_CXT.count;