Fixed warnings which can appear with -Wall -Wextra flags.
Fixed one warning which occurred when it misses a newline at end of a file.