Fix encoding problem on binary file uploads.