[macruby-changes] [2311] MacRuby/trunk/ruby.c

source_changes at macosforge.org source_changes at macosforge.org
Thu Aug 13 15:41:18 PDT 2009


Revision: 2311
          http://trac.macosforge.org/projects/ruby/changeset/2311
Author:   lsansonetti at apple.com
Date:     2009-08-13 15:41:17 -0700 (Thu, 13 Aug 2009)
Log Message:
-----------
taint ARGV and $: in a better way

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

Modified: MacRuby/trunk/ruby.c
===================================================================
--- MacRuby/trunk/ruby.c	2009-08-13 22:40:54 UTC (rev 2310)
+++ MacRuby/trunk/ruby.c	2009-08-13 22:41:17 UTC (rev 2311)
@@ -986,13 +986,8 @@
     opt->xflag = 0;
 
     if (rb_safe_level() >= 4) {
-#if __LP64__
-	RCLASS_RC_FLAGS(rb_argv) &= ~FL_TAINT;
-	RCLASS_RC_FLAGS(rb_vm_load_path()) &= ~FL_TAINT;
-#else
-	FL_UNSET(rb_argv, FL_TAINT);
-	FL_UNSET(rb_vm_load_path(), FL_TAINT);
-#endif
+	OBJ_TAINT(rb_argv);
+	OBJ_TAINT(rb_vm_load_path());
     }
 
     if (opt->do_check) {
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macruby-changes/attachments/20090813/62f846dd/attachment.html>


More information about the macruby-changes mailing list