If you are loosing bytes in the communication process, I hardly see zipping it like a good solution. Anyway, the simplest way for unzipping the received file is using the linux
unzip[
^] command (you might run it from your application via the
system[
^] call).