Sanely recording Binary files

If a file is not a knows text file (java, txt, xml and a few other), then I encode it using base64.

This should solve a lot of problems, including the thing crashing on ADT.