• A
    Avoid PANIC on multiple function execution when using ORCA · 04e43e64
    Adam Berlin 提交于
    A cached query planned statement contains information that is
    freed after the first execution of a function. The second execution
    used the cached planned statement to populate the execution state
    using a freed pointer and throws a segmentation fault.
    
    To resolve, we copy the contents out of the planned statement rather
    than copying a pointer to the planned statement, so that when our
    executor state gets freed, it does not also free the cached data.
    
    Note: `numSelectorsPerScanId` is the problematic property, and is only
    used for partition tables.
    Co-authored-by: NDavid Kimura <dkimura@pivotal.io>
    Co-authored-by: NTaylor Vesely <tvesely@pivotal.io>
    04e43e64
execUtils.c 72.5 KB