If you hava a dial-up connection it will be hard to get a stable configuration of the timeout. But, if you have a DLS connection, you have to configure both the browser timeout and the avast! one.
For IE, the Registry key
HKCU\Software\Microsoft\Windows\CurrentVersion\Internet Settings\ReceiveTimeout
must be correctly set (I suggest a good tweaker: Xteq X-Setup). When IE has sucessfully connected to a webserver, it starts counting until the server closes the connection. If the server does not close the connection, but does also not sent any data, IE will display a “Receive Timeout” after 5 minutes.
I’m not sure but I think the Internet Mail client follow this configuration.
For avast, see the picture (Settings of Internet Mail Provider). 