From 7603463a46b288c1b5630348e36c622e4c2abb09 Mon Sep 17 00:00:00 2001 From: Daniel Black Date: Thu, 16 Nov 2017 20:32:33 +0800 Subject: [PATCH] Remove use of volatile in stored_field_cmp_to_item This was added in c79641594348 but would hurt all other compilers because of Visual Studio. Hopefully this has been fixed now. Signed-off-by: Daniel Black --- sql/item.cc | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/sql/item.cc b/sql/item.cc index 332e027adf1..574e8722c3d 100644 --- a/sql/item.cc +++ b/sql/item.cc @@ -8924,15 +8924,10 @@ int stored_field_cmp_to_item(THD *thd, Field *field, Item *item) } return my_time_compare(&field_time, &item_time); } - /* - The patch for Bug#13463415 started using this function for comparing - BIGINTs. That uncovered a bug in Visual Studio 32bit optimized mode. - Prefixing the auto variables with volatile fixes the problem.... - */ - volatile double result= item->val_real(); + double result= item->val_real(); if (item->null_value) return 0; - volatile double field_result= field->val_real(); + double field_result= field->val_real(); if (field_result < result) return -1; else if (field_result > result)