Make the code as ANSI C compliant.

Current 'master' code contains some C++ things. This commit removes these things.