• T
    Repair bug reported by Wickstrom: backend would crash if WHERE clause · 9d91db4f
    Tom Lane 提交于
    contained a sub-SELECT nested within an AND/OR tree that cnfify()
    thought it should rearrange.  Same physical sub-SELECT node could
    end up linked into multiple places in resulting expression tree.
    This is harmless for most node types, but not for SubLink.
    Repair bug by making physical copies of subexpressions that get
    logically duplicated by cnfify().  Also, tweak the heuristic that
    decides whether it's a good idea to do cnfify() --- we don't really
    want that to happen when it would cause multiple copies of a subselect
    to be generated, I think.
    9d91db4f
subselect.c 20.2 KB