Freeze protection for water-based heating and cooling systems