• Davi Arnaut's avatar
    Bug#50624: crash in check_table_access during call procedure · 07c30f91
    Davi Arnaut authored
    This bug is just one facet of stored routines not being able to
    detect changes in meta-data (WL#4179). This particular problem
    can be triggered within a single session due to the improper
    management of the pre-locking list if the view is expanded after
    the pre-locking list is calculated.
    
    Since the overall solution for the meta-data detection issue is
    planned for a later release, for now a workaround is used to
    fix this particular aspect that only involves a single session.
    The workaround is to flush the thread-local stored routine cache
    every time a view is created or modified, causing locally cached
    routines to be re-evaluated upon invocation.
    
    mysql-test/r/sp-bugs.result:
      Add test case result for Bug#50624.
    mysql-test/t/sp-bugs.test:
      Add test case for Bug#50624.
    sql/sp_cache.cc:
      Update function description.
    sql/sql_view.cc:
      Invalidate the SP cache if a view is being created or modified.
    07c30f91
sp_cache.cc 5.66 KB