fix errors that prevented compilation/running