Backport of subnet/vpc confusion bugfix.