The Analytics tracking code inserts the code so far so good. The problem is that it inserts the code into any downloadable file which contains "<body ". Unfortunately this corrupts the downloads. Wouldn't be possible to check the mime type or so, before changing the content?
Bug in Analytics tracking code