[macruby-changes] [1721] MacRuby/branches/experimental/pack.c

source_changes at macosforge.org source_changes at macosforge.org
Thu Jun 4 14:33:45 PDT 2009


Revision: 1721
          http://trac.macosforge.org/projects/ruby/changeset/1721
Author:   lsansonetti at apple.com
Date:     2009-06-04 14:33:45 -0700 (Thu, 04 Jun 2009)
Log Message:
-----------
taint the resulted bytestring if the given format is tainted

Modified Paths:
--------------
    MacRuby/branches/experimental/pack.c

Modified: MacRuby/branches/experimental/pack.c
===================================================================
--- MacRuby/branches/experimental/pack.c	2009-06-04 16:20:37 UTC (rev 1720)
+++ MacRuby/branches/experimental/pack.c	2009-06-04 21:33:45 UTC (rev 1721)
@@ -453,6 +453,9 @@
     pend = p + RSTRING_LEN(fmt);
 
     VALUE bres = rb_bytestring_new();
+    if (OBJ_TAINTED(fmt)) {
+	OBJ_TAINT(bres);
+    }
     CFMutableDataRef data = rb_bytestring_wrapped_data(bres);
 
     items = RARRAY_LEN(ary);
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macruby-changes/attachments/20090604/92cb668f/attachment.html>


More information about the macruby-changes mailing list