473,537 Members | 2,746 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Handle/Memory Leak in RegistryKey Class?

I seem to be experiencing a behavior on Framework 1.0 sp2 RegistryKey
class where the class is not releasing/closing named pipe winreg
handles to remote machines. The process continues to hold on to a
handle to the following pipe:
\Device\LanmanRedirector\<MACHINE>\PIPE\winreg

Even after explicitly calling Close() (which, according to the docs,
should not matter for a base key), and expliticly doing garbage
collections, I cannot seem to get rid of this pipe.

My app is accessing the registry on thousands of machines and is long
running, and this is not a desired behavior. Any thoughts/help?

example code:

RegistryKey rk = RegistryKey.OpenRemoteBaseKey(RegistryHive.LocalMa chine,
MACHINE) ;
rk.Close();
rk=null;
GC.Collect();
GC.Collect(); // just to allow finalizers, etc.
GC.Collect();

// using tools like SysInternal's Process Explorer shows the winreg
pipe to still be open
Jul 21 '05 #1
0 4069

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
4654
by: Jeremy Lemaire | last post by:
Hello, I am working on cross platform code that is displaying a huge memory leak when compiled on 11.00 HPUX using the aCC -AA flag. It is not leaking on NT, LINUX, Solaris, or HPUX without the -AA flag. In another news group I came across some interesting (ok scarey) information regarding memory leaks in the STL list<...> container. I...
0
1386
by: Kong Li | last post by:
Follow up to this thread, the latest Oracle 9i release 2 patchset (9.2.0.5) fixed the handle count leak problem. The problem is in Oracle client component. Thanks. Kong ----- From: Kong Li (likong@email.com)
3
1517
by: Brad Moore | last post by:
Hey All, I need help with debugging some code, if this isn't the correct newsgroup to ask in, disregard this message. I'm having difficulty pinpointing a memory leak in my code, I believe it has something to do with an inherited class I have, but I fail to see anything wrong. Here is the problematic code. I've hunted the bug down to...
32
3798
by: John | last post by:
Hi all: When I run my code, I find that the memory that the code uses keeps increasing. I have a PC with 2G RAM running Debian linux. The code consumes 1.5G memory by the time it finishes execution. But I do not think it needs so much memory. About 500M memory should be enough. I have following questions about memory leak. (1).If in my...
4
2333
by: Morten Aune Lyrstad | last post by:
Ok, now I'm officially confused. I have a large project going, which uses a win32 ui library I am developing myself. And I'm getting weird memory leaks. I don't know if I can explain what is going on, but I really need some help on this one. Ok, so I have this class defined (written by Randy Charles Morin, www.kbcafe.com) which detects...
20
8034
by: jeevankodali | last post by:
Hi I have an .Net application which processes thousands of Xml nodes each day and for each node I am using around 30-40 Regex matches to see if they satisfy some conditions are not. These Regex matches are called within a loop (like if or for). E.g. for(int i = 0; i < 10; i++) { Regex r = new Regex();
0
412
by: geek_in_a_box | last post by:
I seem to be experiencing a behavior on Framework 1.0 sp2 RegistryKey class where the class is not releasing/closing named pipe winreg handles to remote machines. The process continues to hold on to a handle to the following pipe: \Device\LanmanRedirector\<MACHINE>\PIPE\winreg Even after explicitly calling Close() (which, according to the...
12
1326
by: Grahamo | last post by:
Hey, this is related to absolutely nothing in particular and is of no importance whatsoever except for my curiousity. Does anybody have an example of a particularly tricky memory leak that's hard to spot. I'd like to see something that's a little unusual or obscure. something that involves some in depth knowledge about functionality X...
23
4514
by: James | last post by:
The following code will create memory leaks!!! using System; using System.Diagnostics; using System.Data; using System.Data.SqlClient; namespace MemoryLeak
0
7362
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main...
0
7687
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that...
1
7277
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For...
0
7644
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
0
5826
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then...
0
4846
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert...
0
3343
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
1759
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
1
927
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.