AVG (and other antivirus software) inserts a proxy that catches the email traffic you mention.
The risk with any examining or altering of traffic is that you may be giving up your legal and moral claim to status as a common carrier or safe harbour which is perhaps the only thing protecting you from DMCA and other prosecution in the USA. Microsoft and friends recommend against email scanning http://www.microsoft.com/windows/ie/community/columns/filecorruption.mspx at least for your own email as it may confuse your email software and cause corruption and you are protected anyway due to the antivirus software's file access scanning. Thirdly the default exit policy does not allow exit to port 25 because it can be used by spammers and worms and your ISP may cut off your access as it will think you are the source.

