Comment 2 for bug 317482

Revision history for this message
Jeroen T. Vermeulen (jtv) wrote : Re: Importer gets truncated files

In python 2.4's httplib, according to comments for _safe_read, if a socket's recv() returns no data, there's no way of telling whether it was caused by EINTR or by EOF. (Let's hope that confusion can't happen when the result is nonempty!)

But if that is true, then AFAICS the socket implementation has the same problem while reading a buffer's worth of data, and does not warn about the situation. See socket._fileobject.read, for the "size < 0" case (which is what's being used here). Question is, is it true? I don't see any place where EINTR is being treated specially as a non-error, so probably not.