diff options
author | Jan Lindström <jan.lindstrom@mariadb.com> | 2015-06-24 07:16:08 +0300 |
---|---|---|
committer | Jan Lindström <jan.lindstrom@mariadb.com> | 2015-06-24 07:16:08 +0300 |
commit | 2e4984c185ddcd2da789017cd147338846ff409a (patch) | |
tree | 0293831900c860600efbaa747ea886d9d1cbf5bd /storage/myisam/rt_split.c | |
parent | 792b53e80806df893ee62c9a1c1bd117114c8c6d (diff) | |
parent | a6087e7dc1ef3561d8189c8db15e9591d0f9b520 (diff) | |
download | mariadb-git-10.0-FusionIO.tar.gz |
Merge tag 'mariadb-10.0.20' into 10.0-FusionIO10.0-FusionIO
Conflicts:
storage/innobase/os/os0file.cc
storage/xtradb/os/os0file.cc
storage/xtradb/srv/srv0start.cc
Diffstat (limited to 'storage/myisam/rt_split.c')
-rw-r--r-- | storage/myisam/rt_split.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/storage/myisam/rt_split.c b/storage/myisam/rt_split.c index 9ab0bd99201..be61734e01c 100644 --- a/storage/myisam/rt_split.c +++ b/storage/myisam/rt_split.c @@ -1,5 +1,5 @@ /* - Copyright (c) 2002, 2010, Oracle and/or its affiliates + Copyright (c) 2002, 2015, Oracle and/or its affiliates This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -69,6 +69,10 @@ static double mbr_join_square(const double *a, const double *b, int n_dim) b += 2; }while (a != end); + /* Check for infinity or NaN */ + if (my_isinf(square) || isnan(square)) + square = DBL_MAX; + return square; } @@ -103,6 +107,9 @@ static void pick_seeds(SplitStruct *node, int n_entries, double max_d = -DBL_MAX; double d; + *seed_a = node; + *seed_b = node + 1; + for (cur1 = node; cur1 < lim1; ++cur1) { for (cur2=cur1 + 1; cur2 < lim2; ++cur2) |