Reputation: 27250
I received a "Too many open files" error when tried to do fopen (C++, Windows XP). Probably it happened because somewhere in my program I open files without closing them.
Is there a way on Windows to see a list of all open file descriptors (or all files that my program fopened)?
Upvotes: 2
Views: 366
Reputation: 13055
Rather than look for a Windows API to do it, why not keep track of it yourself? Write some function to do the opening and closing for you, and when they're called, keep track of what is opened and/or closed.
You have the info, so trying to get it from another source seems to make little sense to me.
Upvotes: 0
Reputation: 40700
You can find a list of open handles in Process Explorer. You can also search all open handles in the system.
Upvotes: 2