[PATCH] virTypedParamsValidateTemplate: Fix counting of templates