[macruby-changes] [3396] MacRuby/trunk/object.c

source_changes at macosforge.org source_changes at macosforge.org
Mon Feb 1 08:00:10 PST 2010


Revision: 3396
          http://trac.macosforge.org/projects/ruby/changeset/3396
Author:   pthomson at apple.com
Date:     2010-02-01 08:00:07 -0800 (Mon, 01 Feb 2010)
Log Message:
-----------
Fixed an infinite loop in Object#freeze that only occurs at SAFE level 4.

Modified Paths:
--------------
    MacRuby/trunk/object.c

Modified: MacRuby/trunk/object.c
===================================================================
--- MacRuby/trunk/object.c	2010-02-01 09:59:05 UTC (rev 3395)
+++ MacRuby/trunk/object.c	2010-02-01 16:00:07 UTC (rev 3396)
@@ -1106,7 +1106,7 @@
 {
     if (!OBJ_FROZEN(obj)) {
 	int type;
-	if (rb_safe_level() >= 4 && !OBJ_TAINTED(obj)) {
+	if (rb_safe_level() >= 4 && OBJ_UNTRUSTED(obj)) {
 	    rb_raise(rb_eSecurityError, "Insecure: can't freeze object");
 	}
 	else if (SPECIAL_CONST_P(obj)) {
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macruby-changes/attachments/20100201/a48d10a6/attachment.html>


More information about the macruby-changes mailing list