sockets: Convert file to UTF-8