Avoid "uninitialized" warnings when parsing empty templates

Empty templates are used to squash outgoing mail on a queue-by-queue
basis.
Merge branch '4.0/squash-empty-template-warning' into 4.0-trunk