• Sergey Petrunya's avatar
    MDEV-5037: Server crash on a JOIN on a derived table with join_cache_level > 2 · 422c55a2
    Sergey Petrunya authored
    - The crash was caused because the optimizer called handler->multi_range_read_info()
      on a derived temporary table.  That table has been created, but not opened yet.
      Because of that, handler::table was NULL, which caused crash.
      Fixed by changing DS-MRR methods to use handler::table_share instead. 
      handler::table_share is set in handler ctor, so this should be safe.
    422c55a2
opt_subselect.h 13.5 KB