summaryrefslogtreecommitdiff
path: root/sql/item_cmpfunc.cc
diff options
context:
space:
mode:
authorunknown <pekka@mysql.com>2005-04-01 10:13:37 +0200
committerunknown <pekka@mysql.com>2005-04-01 10:13:37 +0200
commitcb1bdf4d84221312258dd8451f58c06337ff108d (patch)
tree748a9a8f5a64181143501a3ccc782f1dfa1af35f /sql/item_cmpfunc.cc
parent5b0c75259c0b62a0a8efc4964fb70816e1d1954e (diff)
parent8ef1afbaa4ba0c639f2ecf47853086e783cc1efa (diff)
downloadmariadb-git-cb1bdf4d84221312258dd8451f58c06337ff108d.tar.gz
Merge
mysql-test/r/group_by.result: Auto merged ndb/src/kernel/blocks/dbacc/DbaccMain.cpp: Auto merged scripts/make_win_src_distribution.sh: Auto merged sql/item.cc: Auto merged sql/item.h: Auto merged sql/item_subselect.h: Auto merged sql/sql_select.cc: Auto merged ndb/src/kernel/blocks/dbdict/Dbdict.cpp: merge sql/item_cmpfunc.cc: merge support-files/mysql.server.sh: merge
Diffstat (limited to 'sql/item_cmpfunc.cc')
-rw-r--r--sql/item_cmpfunc.cc10
1 files changed, 8 insertions, 2 deletions
diff --git a/sql/item_cmpfunc.cc b/sql/item_cmpfunc.cc
index ddb116f548a..66354560756 100644
--- a/sql/item_cmpfunc.cc
+++ b/sql/item_cmpfunc.cc
@@ -432,10 +432,16 @@ int Arg_comparator::compare_e_binary_string()
int Arg_comparator::compare_real()
{
- double val1= (*a)->val_real();
+ /*
+ Fix yet another manifestation of Bug#2338. 'Volatile' will instruct
+ gcc to flush double values out of 80-bit Intel FPU registers before
+ performing the comparison.
+ */
+ volatile double val1, val2;
+ val1= (*a)->val_real();
if (!(*a)->null_value)
{
- double val2= (*b)->val_real();
+ val2= (*b)->val_real();
if (!(*b)->null_value)
{
owner->null_value= 0;