summaryrefslogtreecommitdiff
path: root/doio.c
diff options
context:
space:
mode:
authorTony Cook <tony@develop-help.com>2017-11-30 15:15:26 +1100
committerTony Cook <tony@develop-help.com>2017-11-30 15:15:26 +1100
commit848643a91802503d27202eb4d302cef07435275e (patch)
tree5d7d5420117d863ecd529c125f0903525aba6038 /doio.c
parent184f90dc410cf3e66a5e682337ae54b3c9f9311f (diff)
downloadperl-848643a91802503d27202eb4d302cef07435275e.tar.gz
(perl #132506) remove an unneeded argument
Diffstat (limited to 'doio.c')
-rw-r--r--doio.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/doio.c b/doio.c
index f15005d299..565f896c01 100644
--- a/doio.c
+++ b/doio.c
@@ -1237,7 +1237,7 @@ S_my_renameat(int olddfd, const char *oldpath, int newdfd, const char *newpath)
#endif
static bool
-S_dir_unchanged(pTHX_ const char *orig_pv, MAGIC *mg, bool is_explicit) {
+S_dir_unchanged(pTHX_ const char *orig_pv, MAGIC *mg) {
Stat_t statbuf;
#ifdef ARGV_USE_STAT_INO
@@ -1275,8 +1275,8 @@ S_dir_unchanged(pTHX_ const char *orig_pv, MAGIC *mg, bool is_explicit) {
return TRUE;
}
-#define dir_unchanged(orig_psv, mg, is_explicit) \
- S_dir_unchanged(aTHX_ (orig_psv), (mg), (is_explicit))
+#define dir_unchanged(orig_psv, mg) \
+ S_dir_unchanged(aTHX_ (orig_psv), (mg))
/* explicit renamed to avoid C++ conflict -- kja */
bool
@@ -1360,7 +1360,7 @@ Perl_do_close(pTHX_ GV *gv, bool not_implicit)
}
#endif
#ifndef ARGV_USE_ATFUNCTIONS
- if (!dir_unchanged(orig_pv, mg, not_implicit))
+ if (!dir_unchanged(orig_pv, mg))
goto abort_inplace;
#endif
if (back_psv && *back_psv) {
@@ -1369,7 +1369,7 @@ Perl_do_close(pTHX_ GV *gv, bool not_implicit)
# ifdef ARGV_USE_ATFUNCTIONS
linkat(dfd, orig_pv, dfd, SvPVX(*back_psv), 0) < 0 &&
!(UNLIKELY(NotSupported(errno)) &&
- dir_unchanged(orig_pv, mg, not_implicit) &&
+ dir_unchanged(orig_pv, mg) &&
link(orig_pv, SvPVX(*back_psv)) == 0)
# else
link(orig_pv, SvPVX(*back_psv)) < 0
@@ -1382,7 +1382,7 @@ Perl_do_close(pTHX_ GV *gv, bool not_implicit)
# ifdef ARGV_USE_ATFUNCTIONS
S_my_renameat(dfd, orig_pv, dfd, SvPVX(*back_psv)) < 0 &&
!(UNLIKELY(NotSupported(errno)) &&
- dir_unchanged(orig_pv, mg, not_implicit) &&
+ dir_unchanged(orig_pv, mg) &&
PerlLIO_rename(orig_pv, SvPVX(*back_psv)) == 0)
# else
PerlLIO_rename(orig_pv, SvPVX(*back_psv)) < 0
@@ -1392,7 +1392,7 @@ Perl_do_close(pTHX_ GV *gv, bool not_implicit)
# ifdef ARGV_USE_ATFUNCTIONS
if (unlinkat(dfd, SvPVX_const(*temp_psv), 0) < 0 &&
UNLIKELY(NotSupported(errno)) &&
- dir_unchanged(orig_pv, mg, not_implicit))
+ dir_unchanged(orig_pv, mg))
(void)UNLINK(SvPVX_const(*temp_psv));
# else
UNLINK(SvPVX(*temp_psv));
@@ -1429,7 +1429,7 @@ Perl_do_close(pTHX_ GV *gv, bool not_implicit)
#elif defined(ARGV_USE_ATFUNCTIONS)
S_my_renameat(dfd, SvPVX(*temp_psv), dfd, orig_pv) < 0 &&
!(UNLIKELY(NotSupported(errno)) &&
- dir_unchanged(orig_pv, mg, not_implicit) &&
+ dir_unchanged(orig_pv, mg) &&
PerlLIO_rename(SvPVX(*temp_psv), orig_pv) == 0)
#else
PerlLIO_rename(SvPVX(*temp_psv), orig_pv) < 0