From 645b9a1bef0847bebfb1ded83b989c762a8358d7 Mon Sep 17 00:00:00 2001 From: Brian Lopez Date: Fri, 9 Jul 2010 09:59:48 -0700 Subject: [PATCH] no need to Check_Type in these spots since we're using StringValuePtr as well --- ext/mysql2/mysql2_ext.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/ext/mysql2/mysql2_ext.c b/ext/mysql2/mysql2_ext.c index db06b32..7dbcd76 100644 --- a/ext/mysql2/mysql2_ext.c +++ b/ext/mysql2/mysql2_ext.c @@ -227,7 +227,6 @@ static VALUE rb_mysql_client_query(int argc, VALUE * argv, VALUE self) { args.sql = rb_str_export_to_enc(args.sql, conn_enc); #endif - Check_Type(args.sql, T_STRING); Data_Get_Struct(self, MYSQL, client); REQUIRE_OPEN_DB(client); @@ -273,7 +272,6 @@ static VALUE rb_mysql_client_escape(VALUE self, VALUE str) { str = rb_str_export_to_enc(str, conn_enc); #endif - Check_Type(str, T_STRING); oldLen = RSTRING_LEN(str); char escaped[(oldLen*2)+1];