Skip to content

Commit

Permalink
Fixup for MDEV-18968
Browse files Browse the repository at this point in the history
Item_cond::eval_not_null_tables(): Use Item::eval_const_cond(),
just like Item_cond::fix_fields().

This inconsistency was found while merging to 10.3, where the
Microsoft compiler is configured to report an error for comparing
longlong to bool.
  • Loading branch information
dr-m committed Mar 26, 2019
1 parent f2c1c95 commit 762419a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions sql/item_cmpfunc.cc
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/* Copyright (c) 2000, 2013, Oracle and/or its affiliates.
Copyright (c) 2009, 2016, MariaDB
Copyright (c) 2009, 2019, MariaDB
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
Expand Down Expand Up @@ -4728,7 +4728,7 @@ Item_cond::eval_not_null_tables(uchar *opt_arg)
if (item->const_item() && !item->with_param &&
!item->is_expensive() && !cond_has_datetime_is_null(item))
{
if (item->val_int() == is_and_cond && top_level())
if (item->eval_const_cond() == is_and_cond && top_level())
{
/*
a. This is "... AND true_cond AND ..."
Expand Down

0 comments on commit 762419a

Please sign in to comment.