diff --git a/leveldb.go b/leveldb.go index ee1e08d..63a5530 100644 --- a/leveldb.go +++ b/leveldb.go @@ -356,7 +356,7 @@ func (ldbs *LevelDBSession) interleavedSpatialQuery(first, second []byte, done c } it.Next() } else { - it.Seek(common.ToBigEndian(common.NaiveBigMin(zmin, zmax, zcode))) + it.Seek(common.ToBigEndian(common.BigMin(zmin, zmax, zcode))) } } if err = it.GetError(); err != nil { diff --git a/sqlite.go b/sqlite.go index 3ce7c90..bc6c5cf 100644 --- a/sqlite.go +++ b/sqlite.go @@ -353,7 +353,7 @@ func (ss *SqliteSession) interleavedSpatialQuery(first, second []byte, done chan } } else { // Left the cuboid rows.Close() - zmin = common.NaiveBigMin(zmin, zmax, zcode) + zmin = common.BigMin(zmin, zmax, zcode) continue OUTER } }