public inbox for cygwin-cvs@sourceware.org
help / color / mirror / Atom feed
From: Corinna Vinschen <corinna@sourceware.org>
To: cygwin-cvs@sourceware.org
Subject: [newlib-cygwin] Cygwin: AF_UNIX: use Nt functions within Nt functions
Date: Fri, 28 Feb 2020 11:43:00 -0000	[thread overview]
Message-ID: <20200228114301.29809.qmail@sourceware.org> (raw)

https://sourceware.org/git/gitweb.cgi?p=newlib-cygwin.git;h=f5357141ade956d8057e76b0a5e58f5069a6d399

commit f5357141ade956d8057e76b0a5e58f5069a6d399
Author: Corinna Vinschen <corinna@vinschen.de>
Date:   Fri Feb 28 12:40:49 2020 +0100

    Cygwin: AF_UNIX: use Nt functions within Nt functions
    
    Functionaly equivalent, but makes for cleaner code
    
    Signed-off-by: Corinna Vinschen <corinna@vinschen.de>

Diff:
---
 winsup/cygwin/fhandler_socket_unix.cc | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/winsup/cygwin/fhandler_socket_unix.cc b/winsup/cygwin/fhandler_socket_unix.cc
index 824bcba..760f210 100644
--- a/winsup/cygwin/fhandler_socket_unix.cc
+++ b/winsup/cygwin/fhandler_socket_unix.cc
@@ -1436,10 +1436,10 @@ fhandler_socket_unix::socketpair (int af, int type, int protocol, int flags,
 fh_open_pipe_failed:
   NtClose (pipe);
 create_pipe_failed:
-  NtUnmapViewOfSection (GetCurrentProcess (), fh->shmem);
+  NtUnmapViewOfSection (NtCurrentProcess (), fh->shmem);
   NtClose (fh->shmem_handle);
 fh_shmem_failed:
-  NtUnmapViewOfSection (GetCurrentProcess (), shmem);
+  NtUnmapViewOfSection (NtCurrentProcess (), shmem);
   NtClose (shmem_handle);
   return -1;
 }
@@ -1814,7 +1814,7 @@ fhandler_socket_unix::close ()
     NtClose (shm);
   param = InterlockedExchangePointer ((PVOID *) &shmem, NULL);
   if (param)
-    NtUnmapViewOfSection (GetCurrentProcess (), param);
+    NtUnmapViewOfSection (NtCurrentProcess (), param);
   return 0;
 }


                 reply	other threads:[~2020-02-28 11:43 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20200228114301.29809.qmail@sourceware.org \
    --to=corinna@sourceware.org \
    --cc=cygwin-cvs@sourceware.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).