Fix segfault with zones without endpoints on config compile.

Fixes #6425