Fixed warnings from gcc -Wall