Notice: This website is an unofficial Microsoft Knowledge Base (hereinafter KB) archive and is intended to provide a reliable access to deleted content from Microsoft KB. All KB articles are owned by Microsoft Corporation. Read full disclaimer for more details.

FIX: A program that frequently uses the System.Net.WebRequest method experiences an OutOfMemoryException error in the .NET Framework 1.0 Service Pack 3

View products that this article applies to.


If you create a program by using the Microsoft .NET Framework 1.0 Service Pack 3 (SP3), and the program frequently uses the System.Net.WebRequest method, you experience an OutOfMemoryException error when you run the program.

↑ Back to the top


The .NET Framework uses the ServicePoint class to handle connections to the Internet. If the Web browser is configured to use a proxy server, only one ServicePoint connection object is created for all the connections for each program. However, if the computer is directly connected to the Internet, and the Web browser is not configured to use a proxy server, a ServicePoint connection object is created for each unique connection.

The System.Net namespace pins some memory to make a native call every time that the WebRequest object is invoked. However, the memory is not correctly collected when the ServicePoint object is disposed. If a program creates many ServicePoint objects, an OutOfMemoryException error occurs because the memory becomes fragmented in the unmanaged heap.

This problem may also occur if the computer is configured behind a proxy or behind a firewall that has a firewall client installed and the Web browser is not configured to use a proxy server.

↑ Back to the top


Software update information

A supported hotfix is now available from Microsoft, but it is only intended to correct the problem that is described in this article. Only apply it to systems that are experiencing this specific problem. This hotfix may receive additional testing. Therefore, if you are not severely affected by this problem, we recommend that you wait for the next Microsoft .NET Framework 1.0 service pack that contains this hotfix.

To resolve this problem immediately, contact Microsoft Product Support Services to obtain the hotfix. For a complete list of Microsoft Product Support Services telephone numbers and information about support costs, visit the following Microsoft Web site:Note In special cases, charges that are ordinarily incurred for support calls may be canceled if a Microsoft Support Professional determines that a specific update will resolve your problem. The usual support costs will apply to additional support questions and issues that do not qualify for the specific update in question.


Microsoft .NET Framework 1.0 SP3

Restart requirement

You must restart the computer after you apply this software update.

Software update replacement information

This software update does not replace any other software updates.

File information

The English version of this software update has the file attributes (or later) that are listed in the following table. The dates and times for these files are listed in coordinated universal time (UTC). When you view the file information, it is converted to local time. To find the difference between UTC and local time, use the Time Zone tab in the Date and Time tool in Control Panel.
   Date           Time       Version        Size       File name
   20-April-2005  18:41:58   1.0.3705.6036  1,179,648  System.dll

↑ Back to the top


To work around this problem, configure the Web browser to use a proxy server. To do this, follow these steps:
  1. Start Microsoft Internet Explorer.
  2. On the Tools menu, click Internet Options.
  3. Click the Connections tab, and then click LAN Settings.
  4. Under Proxy server, click to select the Use a proxy server for your LAN check box.
  5. In the Address box, type the IP address of the proxy server.
  6. In the Port box, type the port number that is used by the proxy server for client connections. By default, this port number is 8080.
  7. If you do not want to use the proxy server computer when you connect to a computer that is on the local network, click to select the Bypass proxy server for local addresses check box. This change may speed up performance.
  8. Click OK two times.

↑ Back to the top


Microsoft has confirmed that this is a problem in the Microsoft products that are listed in the "Applies to" section.

↑ Back to the top

More information

For more information about how to configure Internet Explorer to use a proxy server, click the following article number to view the article in the Microsoft Knowledge Base:
135982 How to configure Internet Explorer to use a proxy server
For more information, click the following article number to view the article in the Microsoft Knowledge Base:
824684 Description of the standard terminology that is used to describe Microsoft software updates

↑ Back to the top

Keywords: KB893315, kbnetframe100presp3fix, kbfix, kbbug, kbqfe, kbhotfixserver

↑ Back to the top

Article Info
Article ID : 893315
Revision : 2
Created on : 9/28/2011
Published on : 9/28/2011
Exists online : False
Views : 361