r10145: add patch for collect-table-refs