diff options
author | unknown <timour@askmonty.org> | 2011-03-30 10:10:59 +0300 |
---|---|---|
committer | unknown <timour@askmonty.org> | 2011-03-30 10:10:59 +0300 |
commit | 952556b3452d4a6893a678da88809b22e7f7a466 (patch) | |
tree | 938de6db815840eb2038bdded942ab684e4673d0 /sql/item_sum.cc | |
parent | 9762b236d47e74f2f065c89a747c1a8d3444ed18 (diff) | |
parent | 0737fb479f082c424881e79e4c358670176ebca2 (diff) | |
download | mariadb-git-952556b3452d4a6893a678da88809b22e7f7a466.tar.gz |
MWL#89
Merge 5.3 with 5.3-mwl89.
Diffstat (limited to 'sql/item_sum.cc')
-rw-r--r-- | sql/item_sum.cc | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/sql/item_sum.cc b/sql/item_sum.cc index 7de02d726fa..f937394613e 100644 --- a/sql/item_sum.cc +++ b/sql/item_sum.cc @@ -1053,9 +1053,10 @@ bool Item_sum_distinct::unique_walk_function(void *element) void Item_sum_distinct::clear() { DBUG_ENTER("Item_sum_distinct::clear"); - DBUG_ASSERT(tree != 0); /* we always have a tree */ + /* During EXPLAIN there is no tree because it is created during execution. */ + if (tree != 0) + tree->reset(); null_value= 1; - tree->reset(); is_evaluated= FALSE; DBUG_VOID_RETURN; } |