From e23d40ed7487554f753b8621bcc1f8befdee46d8 Mon Sep 17 00:00:00 2001 From: Lewis Buckley Date: Wed, 29 Mar 2023 09:16:51 +0100 Subject: [PATCH] Support microseconds See also https://github.com/makandra/mysql2/commit/56b46c8b88c9e720d08b743d9b43154ad09484c3 --- ext/mysql2/result.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/mysql2/result.c b/ext/mysql2/result.c index 5b8a5b162..9054ed545 100644 --- a/ext/mysql2/result.c +++ b/ext/mysql2/result.c @@ -297,7 +297,7 @@ static VALUE rb_mysql_result_fetch_row(VALUE self, ID db_timezone, ID app_timezo break; } msec = msec_char_to_uint(msec_char, sizeof(msec_char)); - val = rb_funcall(rb_cTime, db_timezone, 6, opt_time_year, opt_time_month, opt_time_month, UINT2NUM(hour), UINT2NUM(min), UINT2NUM(sec), UINT2NUM(msec)); + val = rb_funcall(rb_cTime, db_timezone, 7, opt_time_year, opt_time_month, opt_time_month, UINT2NUM(hour), UINT2NUM(min), UINT2NUM(sec), UINT2NUM(msec)); if (!NIL_P(app_timezone)) { if (app_timezone == intern_local) { val = rb_funcall(val, intern_localtime, 0);