Fixed all compiler warnings (when using pedantic warning settings).