summaryrefslogtreecommitdiffhomepage
path: root/src
diff options
context:
space:
mode:
authormidipix <writeonce@midipix.org>2017-08-04 22:22:22 +0000
committermidipix <writeonce@midipix.org>2017-08-04 17:33:16 -0400
commit93e3aa4e1c29098ffc2b2b74b445198593936e97 (patch)
tree41a444afef51b7db384242498928d9bbbc3cb8f9 /src
parent239da0d84d764de4307fb4aaaa6b6444118f24c8 (diff)
downloadntapi-93e3aa4e1c29098ffc2b2b74b445198593936e97.tar.bz2
ntapi-93e3aa4e1c29098ffc2b2b74b445198593936e97.tar.xz
__ipc_connect_by_attr(): return section-related info in the _by_port code path.
Diffstat (limited to 'src')
-rw-r--r--src/ipc/ntapi_ipc_connect.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/src/ipc/ntapi_ipc_connect.c b/src/ipc/ntapi_ipc_connect.c
index fe3561a..fceb527 100644
--- a/src/ipc/ntapi_ipc_connect.c
+++ b/src/ipc/ntapi_ipc_connect.c
@@ -63,12 +63,9 @@ static int32_t __ipc_connect_by_attr(
&attr->guid,
&conn->guid)) {
/* already connected */
- if (hconn)
+ if (hconn && ((uintptr_t)hconn != node->key))
return __ipc_connect_return(
- hlock,
- ((uintptr_t)hconn == node->key)
- ? NT_STATUS_SUCCESS
- : NT_STATUS_CONTEXT_MISMATCH);
+ hlock,NT_STATUS_CONTEXT_MISMATCH);
*hport = (void *)node->key;
*hsection = ipc->hsection;