• Sergey Petrunya's avatar
    Backport the following from 5.5 to 5.3: · 6ebaa493
    Sergey Petrunya authored
    MDEV-4556 Server crashes in SEL_ARG::rb_insert with index_merge+index_merge_sort_union, FORCE INDEX
    - merge_same_index_scans() may put the same SEL_ARG tree in multiple result plans.
      make it call incr_refs() on the SEL_ARG trees that it does key_or() on, because 
      key_or(sel_arg_tree_1, sel_arg_tree_2) call may invalidate SEL_ARG trees pointed 
      by sel_arg_tree_1 and sel_arg_tree_2.
        
    6ebaa493
index_merge_myisam.test 5.26 KB