DRYed up async_query a bit

This commit is contained in:
oldmoe 2008-08-27 02:43:17 +03:00
parent d7e47a3f2d
commit fa9c977d54

View File

@ -806,9 +806,7 @@ static VALUE get_result(VALUE obj)
static VALUE async_query(VALUE obj, VALUE sql) static VALUE async_query(VALUE obj, VALUE sql)
{ {
send_query(obj,sql); send_query(obj,sql);
MYSQL* m = GetHandler(obj); rb_io_wait_readable(socket(obj));
int sd = (int)vio_fd(m->net.vio);
rb_io_wait_readable(sd);
return get_result(obj); return get_result(obj);
} }