[svn:parrot] r48889 - trunk/src/pmc

NotFound at svn.parrot.org NotFound at svn.parrot.org
Thu Sep 9 20:20:26 UTC 2010


Author: NotFound
Date: Thu Sep  9 20:20:26 2010
New Revision: 48889
URL: https://trac.parrot.org/parrot/changeset/48889

Log:
drop a no longer needed call to STRING_validate in ByteBuffer, the tests will avoid regressions

Modified:
   trunk/src/pmc/bytebuffer.pmc

Modified: trunk/src/pmc/bytebuffer.pmc
==============================================================================
--- trunk/src/pmc/bytebuffer.pmc	Thu Sep  9 20:10:43 2010	(r48888)
+++ trunk/src/pmc/bytebuffer.pmc	Thu Sep  9 20:20:26 2010	(r48889)
@@ -393,16 +393,10 @@
         ARGIN_NULLOK(const STR_VTABLE *encoding))
 {
     ASSERT_ARGS(build_string)
-    STRING *result;
     if (encoding == NULL)
         Parrot_ex_throw_from_c_args(interp, NULL, EXCEPTION_INVALID_ENCODING,
                 "Invalid encoding");
-    result = Parrot_str_new_init(interp, (const char *)content, size, encoding, 0);
-    if (!STRING_validate(interp, result))
-        Parrot_ex_throw_from_c_args(interp, NULL,
-                EXCEPTION_INVALID_STRING_REPRESENTATION,
-                "Invalid buffer content");
-    return result;
+    return Parrot_str_new_init(interp, (const char *)content, size, encoding, 0);
 }
 
 /*


More information about the parrot-commits mailing list