Fixed errors uncovered by g++/clang++ when configured with "-Wextra" CFLAGS.