Jeff T.
Jeff T.

Reputation: 2271

VS continues on Debug session means memory leak, after closing the application?

If Visual Studio keeps in Debug session and doesn't stop debugging to switch into the Edit session, could I say there MUST be some memory leak in my program after I already closed it from the program itself, especially in C# condition ?

Upvotes: 0

Views: 116

Answers (1)

fxam
fxam

Reputation: 3982

I don't think so. A program running without memory leak can still be running even after a user has asked the program to quit. This can be caused by bugs in the program or library. The bug could be that a thread is still running at the background, or a code is waiting for something that never happens. In Visual Studio, you can press Ctrl+Break or click "Debug -> Break All" to see what code or threads are still running.

But of course from another point of view, you can consider a program that won't quit is leaking memory, since it occupies system memory unless user intervenes and kills it.

Upvotes: 1

Related Questions