]> granicus.if.org Git - postgis/commitdiff
handled special case of Inf boxes as GiST keys in picksplit
authorSandro Santilli <strk@keybit.net>
Wed, 2 Jun 2004 22:43:54 +0000 (22:43 +0000)
committerSandro Santilli <strk@keybit.net>
Wed, 2 Jun 2004 22:43:54 +0000 (22:43 +0000)
git-svn-id: http://svn.osgeo.org/postgis/trunk@565 b70326c6-7e19-0410-871a-916f4a2858ee

postgis_gist_72.c

index 5f61b1c0d27ae85cb865c0b0dba5aeaeff4a5360..a399dd3a00980b198e219bf9c0d123131e566ab1 100644 (file)
@@ -11,6 +11,9 @@
  *
  **********************************************************************
  * $Log$
+ * Revision 1.12  2004/06/02 22:43:54  strk
+ * handled special case of Inf boxes as GiST keys in picksplit
+ *
  * Revision 1.11  2004/04/28 22:26:02  pramsey
  * Fixed spelling mistake in header text.
  *
@@ -555,8 +558,12 @@ gbox_picksplit(PG_FUNCTION_ARGS)
                                        ADDLIST(listT, unionT, posT,arr[i-1].pos);
                                else
                                        ADDLIST(listB, unionB, posB,arr[i-1].pos);
-                       } else
-                               ADDLIST(listT, unionT, posT,arr[i-1].pos);
+                       } else {
+                               if ( posB>posT )
+                                       ADDLIST(listT, unionT, posT,arr[i-1].pos);
+                               else
+                                       ADDLIST(listB, unionB, posB,arr[i-1].pos);
+                       }
                }
                pfree(arr);
        }