Added newlines and fixed compiler warnings.