Minor cleanup to compile without warnings (GCC)
Started cleanup to compile cleanly with clang
Tested on FreeBSD (x86) and ArchLinux (ARM)