I have the same problem and cannot offer a good solution (besides what Tood suggests, which is an option). But looking at the situation with fiddler & co., I have some more information that may be of help.
Our application is creating PDF documents on the fly and offering them as downloads. The issue is clearly data-dependent, meaning that some generated files download fine on the first attempt while others reproducibly need the retry.
Fiddler shows the server responses to be identical on each access, as far as I can tell. The requests differ, however (samples slightly edited):
First request:
GET http://localhost:12345/Item/PDF/id HTTP/1.1
Accept: text/html, application/xhtml+xml, */*
Referer: ...
Accept-Language: ...
User-Agent: Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; WOW64; Trident/5.0)
Accept-Encoding: gzip, deflate
Host: localhost:12345
Connection: Keep-Alive
Cookie: ASP.NET_SessionId=52znkt1fcisrolj44tnuyzu4
Second request:
GET http://localhost:12345/Item/PDF/id HTTP/1.1
Accept: */*
Accept-Encoding: gzip, deflate
User-Agent: Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; WOW64; Trident/5.0)
Host: localhost:12345
Connection: Keep-Alive
Cookie: ASP.NET_SessionId=52znkt1fcisrolj44tnuyzu4
Note, how the second request reduces the 'Accept:' header to just */*
. The reason that I'm reluctant to add a file extension to the Url is that the suggested download name is generated from item data, submitted with the response and otherwise totally unrelated to the ID.