fixed compiler error (closes #562)
added missing semi-colons and removed dead code