Fix up terminate/1 calls