[前][次][番号順一覧][スレッド一覧]

ruby-changes:30588

From: akr <ko1@a...>
Date: Fri, 23 Aug 2013 20:53:17 +0900 (JST)
Subject: [ruby-changes:30588] akr:r42667 (trunk): Fix the previous commit.

akr	2013-08-23 20:53:12 +0900 (Fri, 23 Aug 2013)

  New Revision: 42667

  http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=42667

  Log:
    Fix the previous commit.

  Modified files:
    trunk/ChangeLog
    trunk/process.c
Index: ChangeLog
===================================================================
--- ChangeLog	(revision 42666)
+++ ChangeLog	(revision 42667)
@@ -1,4 +1,4 @@ https://github.com/ruby/ruby/blob/trunk/ChangeLog#L1
-Fri Aug 23 19:40:50 2013  Tanaka Akira  <akr@f...>
+Fri Aug 23 20:50:40 2013  Tanaka Akira  <akr@f...>
 
 	* process.c (gcd_ul): New function.
 	  (reduce_fraction): Ditto.
Index: process.c
===================================================================
--- process.c	(revision 42666)
+++ process.c	(revision 42667)
@@ -6888,7 +6888,6 @@ make_clock_result(struct timetick *ttp, https://github.com/ruby/ruby/blob/trunk/process.c#L6888
 VALUE
 rb_clock_gettime(int argc, VALUE *argv)
 {
-    struct timespec ts;
     VALUE clk_id, unit;
     int ret;
 
@@ -7006,13 +7005,14 @@ rb_clock_gettime(int argc, VALUE *argv) https://github.com/ruby/ruby/blob/trunk/process.c#L7005
             tt.count = t % 1000000000;
             tt.giga_count = t / 1000000000;
             numerator = sTimebaseInfo.numer;
-            denominator = sTimebaseInfo.denom;
+            denominator = sTimebaseInfo.denom * 1000000000;
             goto success;
         }
 #endif
     }
     else {
 #if defined(HAVE_CLOCK_GETTIME)
+        struct timespec ts;
         clockid_t c;
         c = NUM2CLOCKID(clk_id);
         ret = clock_gettime(c, &ts);

--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]