Minor cleanup on c code