diff options
author | Adam <you@example.com> | 2020-05-17 05:51:50 +0200 |
---|---|---|
committer | Adam <you@example.com> | 2020-05-17 05:51:50 +0200 |
commit | e611b132f9b8abe35b362e5870b74bce94a1e58e (patch) | |
tree | a5781d2ec0e085eeca33cf350cf878f2efea6fe5 /private/csr/server/semphore | |
download | NT4.0-e611b132f9b8abe35b362e5870b74bce94a1e58e.tar NT4.0-e611b132f9b8abe35b362e5870b74bce94a1e58e.tar.gz NT4.0-e611b132f9b8abe35b362e5870b74bce94a1e58e.tar.bz2 NT4.0-e611b132f9b8abe35b362e5870b74bce94a1e58e.tar.lz NT4.0-e611b132f9b8abe35b362e5870b74bce94a1e58e.tar.xz NT4.0-e611b132f9b8abe35b362e5870b74bce94a1e58e.tar.zst NT4.0-e611b132f9b8abe35b362e5870b74bce94a1e58e.zip |
Diffstat (limited to 'private/csr/server/semphore')
-rw-r--r-- | private/csr/server/semphore | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/private/csr/server/semphore b/private/csr/server/semphore new file mode 100644 index 000000000..df3ef3edd --- /dev/null +++ b/private/csr/server/semphore @@ -0,0 +1,30 @@ +To prevent deadlock, semaphores must be taken in the following +order: + + ProcessStructureLock + ProcessLock + ThreadLock + CurrentConsoleLock + ConsoleHandleTableLock + ConsoleLock + ReadCountLock (console) + WaitListsLock + + +ProcessStructureLock - + must be held to change process or thread structure. + held while traversing process/thread tree. always must be held + when calling CsrLocateThreadByClientId. + +ProcessLock - + must be held exclusively to destroy a process + can be held shared or exclusive. + held shared for during of an api call so that process isn't destroyed + by another process during call. + held exclusively means that no one else can access contents + +ThreadLock - + must be held exclusively to destroy a thread + can be held shared or exclusive. + held shared for during of an api call so that thread isn't destroyed + by another thread during call. |