Fix warnings about encoding