mike5 Posted May 28, 2010 Report Share Posted May 28, 2010 Hi all, I have a question: If I create an object and then a Data Value Reference to it, then I pass that reference around, but when I'm finished with it, I don't release it, but just forget about it... Does this cause a memory leak, or is the memory reclaimed? Br, Mike Quote Link to comment
Daklu Posted May 28, 2010 Report Share Posted May 28, 2010 Are you referring to a memory leak in Labview or in your application? I haven't seen anything that indicates Labview has a memory leak when DVR's are not cleaned up properly. When the vi or application stops running the memory will be reclaimed. As for a leak in your application, my best guess is that it depends on your code. Labview generally retains data in memory as long as the vi that created the data remains active. If you create the DVR in your top level vi LV won't automatically reclaim the memory until that vi goes idle. Quote Link to comment
mike5 Posted May 31, 2010 Author Report Share Posted May 31, 2010 Thank you. I'm creating an app that will run for extended periods of time and is using DVRs a lot. It occurred to me that if the app creates a lot of objects and creates DVRs to them without releasing them, it might become a problem. But I wanted to be sure, so thanks for the answer. In short, if I create DVRs, I better release them once they are not needed any more.... Br, Mike Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.