[Groonga-commit] groonga/groonga [master] fix a milliseconds -> dgree geo point conversion logic.

Back to archive index

null+****@clear***** null+****@clear*****
2010年 9月 9日 (木) 11:55:53 JST


Kouhei Sutou	2010-09-09 02:55:53 +0000 (Thu, 09 Sep 2010)

  New Revision: 5da6a9c7e5be27e7545266a051468411f0e9df3f

  Log:
    fix a milliseconds -> dgree geo point conversion logic.

  Modified files:
    test/unit/lib/grn-test-utils.c

  Modified: test/unit/lib/grn-test-utils.c (+1 -6)
===================================================================
--- test/unit/lib/grn-test-utils.c    2010-09-08 23:47:34 +0000 (fbee3c4)
+++ test/unit/lib/grn-test-utils.c    2010-09-09 02:55:53 +0000 (a619e2d)
@@ -750,12 +750,7 @@ grn_test_coordinate_in_milliseconds(gdouble coordinate_in_degree)
 gdouble
 grn_test_coordinate_in_degree(gint coordinate_in_milliseconds)
 {
-  gdouble coordinate_in_degree = 0;
-
-  coordinate_in_degree += (coordinate_in_milliseconds % 3600) * 0.0000001;
-  coordinate_in_degree += (coordinate_in_milliseconds / 3600.0) * 0.001;
-
-  return coordinate_in_degree;
+  return (coordinate_in_milliseconds / 3600.0) * 0.001;
 }
 
 const gchar *




Groonga-commit メーリングリストの案内
Back to archive index