Fix parallel index builds for dynamic_shared_memory_type=none.
authorRobert Haas <rhaas@postgresql.org>
Mon, 12 Feb 2018 17:55:12 +0000 (12:55 -0500)
committerRobert Haas <rhaas@postgresql.org>
Mon, 12 Feb 2018 17:55:12 +0000 (12:55 -0500)
commit88ef48c1ccee6a2200e01318180cf521413b3012
tree1f83ddcf47de36b07cc1bab85737008a8eb02bba
parent80f021ef139affdb219ccef71fff283e8f91f112
Fix parallel index builds for dynamic_shared_memory_type=none.

The previous code failed to realize that this setting effectively
disables parallelism, and would crash if it decided to attempt
parallelism anyway.  Instead, treat it as a disabling condition.

Kyotaro Horiguchi, who also reported the issue. Reviewed by Michael
Paquier and Peter Geoghegan.

Discussion: http://postgr.es/m/20180209.170635.256350357.horiguchi.kyotaro@lab.ntt.co.jp
src/backend/optimizer/plan/planner.c