Fix issues observed by Sun C compiler