From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 2155) id 061213858D38; Fri, 8 Sep 2023 20:41:41 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 061213858D38 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1694205701; bh=SmKc6W27yFGFUtvynFEa1ijPvJzqRe9jbpC5E1e/FSo=; h=From:To:Subject:Date:From; b=iYlpjiSl0mDztyjcsGk4A6mHg3iyPKH9eMs9dIUSZhXk6e7TTyNZBiMigYwWWXZ9K fpxwZ47Uu6viQ209eLD3jPnT3ks4yWONQbFfe5NP2HSC77Td12tDYMc6KkX9A3IUTA 6L9iBqxigwlETFPFyBphHZuaSHG10hI0ZxEcUMP4= Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable From: Corinna Vinschen To: cygwin-cvs@sourceware.org Subject: [newlib-cygwin/main] Cygwin: unlink_nt: declare in winsup.h X-Act-Checkin: newlib-cygwin X-Git-Author: Corinna Vinschen X-Git-Refname: refs/heads/main X-Git-Oldrev: 7ced682549ae718db29121013c84ce8057bc3509 X-Git-Newrev: 53472e1803808d5fb91029f4c26c86989c62c82c Message-Id: <20230908204141.061213858D38@sourceware.org> Date: Fri, 8 Sep 2023 20:41:41 +0000 (GMT) List-Id: https://sourceware.org/git/gitweb.cgi?p=3Dnewlib-cygwin.git;h=3D53472e18038= 08d5fb91029f4c26c86989c62c82c commit 53472e1803808d5fb91029f4c26c86989c62c82c Author: Corinna Vinschen AuthorDate: Fri Sep 8 22:34:52 2023 +0200 Commit: Corinna Vinschen CommitDate: Fri Sep 8 22:34:52 2023 +0200 Cygwin: unlink_nt: declare in winsup.h =20 unlink_nt is used more than once so declare it in a header. =20 Signed-off-by: Corinna Vinschen Diff: --- winsup/cygwin/fhandler/disk_file.cc | 2 -- winsup/cygwin/forkable.cc | 4 ---- winsup/cygwin/local_includes/winsup.h | 2 ++ 3 files changed, 2 insertions(+), 6 deletions(-) diff --git a/winsup/cygwin/fhandler/disk_file.cc b/winsup/cygwin/fhandler/d= isk_file.cc index 94f7ef566756..d59cde78b5bd 100644 --- a/winsup/cygwin/fhandler/disk_file.cc +++ b/winsup/cygwin/fhandler/disk_file.cc @@ -1842,8 +1842,6 @@ fhandler_disk_file::mkdir (mode_t mode) int fhandler_disk_file::rmdir () { - extern NTSTATUS unlink_nt (path_conv &pc, bool sharable); - if (!pc.isdir ()) { set_errno (ENOTDIR); diff --git a/winsup/cygwin/forkable.cc b/winsup/cygwin/forkable.cc index c69c8bea9e98..cd317a1ae09e 100644 --- a/winsup/cygwin/forkable.cc +++ b/winsup/cygwin/forkable.cc @@ -27,10 +27,6 @@ details. */ #include #include =20 -/* Allow concurrent processes to use the same dll or exe - * via their hardlink while we delete our hardlink. */ -extern NTSTATUS unlink_nt (path_conv &pc, bool sharable); - #define MUTEXSEP L"@" #define PATHSEP L"\\" =20 diff --git a/winsup/cygwin/local_includes/winsup.h b/winsup/cygwin/local_in= cludes/winsup.h index c9788de8f012..bf0a0bcc3fc0 100644 --- a/winsup/cygwin/local_includes/winsup.h +++ b/winsup/cygwin/local_includes/winsup.h @@ -225,6 +225,8 @@ class path_conv; =20 int stat_worker (path_conv &pc, struct stat *buf); =20 +NTSTATUS unlink_nt (path_conv &pc, bool sharable); + ino_t readdir_get_ino (const char *path, bool dot_dot); =20 /* mmap functions. */