• Davi Arnaut's avatar
    Bug#48449: hang on show create view after upgrading when view contains function of view · be632a2f
    Davi Arnaut authored
    SHOW CREATE TABLE on a view (v1) that contains a function whose
    statement uses another view (v2), could trigger a infinite loop
    if the view referenced within the function causes a warning to
    be raised while opening the said view (v2).
    
    The problem was a infinite loop over the stack of internal error
    handlers. The problem would be triggered if the stack contained
    two or more handlers and the first two handlers didn't handle the
    raised condition. In this case, the loop variable would always
    point to the second handler in the stack.
    
    The solution is to correct the loop variable assignment so that
    the loop is able to iterate over all handlers in the stack.
    be632a2f
view.test 97.6 KB