There is a global mutex used by different applications. If one application blocks this mutex then other applications will not be able to start. Given the mutex name how can I find out in C# which process is owning this mutex currently. I need to build a utility to findout this process and kill which is holding this mutex.
Asked
Active
Viewed 1,676 times
0
-
2[Win32: How to get the process/thread that owns a mutex?](http://stackoverflow.com/questions/1947312/win32-how-to-get-the-process-thread-that-owns-a-mutex) – Jason Evans Feb 29 '16 at 10:20
1 Answers
0
By the looks of it, there's no simple c# only way to do so:
There's nothing in .NET to tell who "owns" a mutex. You'd have to PInvoke a set of functions with some very complicated code to get the current owner of a mutex.
Carlos
- 5,778
- 6
- 44
- 80