Further fixes and improvements.