diff options
author | Sergey Poznyakoff <gray@gnu.org> | 2020-04-13 21:50:15 +0300 |
---|---|---|
committer | Sergey Poznyakoff <gray@gnu.org> | 2020-04-13 22:32:40 +0300 |
commit | 2f3ec2402f827066cb55ae562154106433d29ac2 (patch) | |
tree | 87e650e32e90da305478c17e1e9730932e4e3c50 /src/lock.c | |
parent | a9d38e5de5cceb667bec3db15fed68f7e8d96a8b (diff) | |
download | wydawca-2f3ec2402f827066cb55ae562154106433d29ac2.tar.gz wydawca-2f3ec2402f827066cb55ae562154106433d29ac2.tar.bz2 |
Rewrite diskio function so as not to assume any particular cwd
* src/backup.c (get_backup_suffix)
(find_backup_file_name): Get directory descriptor as first argument.
* src/diskio.c: Rewrite using *at() functions.
* src/gpg.c (rmdir_r): Silently skip ENOENT.
(verify_detached_signature): push_dir/pop_dir.
* src/triplet.c: Don't change to spool->source_dir. Underlying
functions don't assume any specific cwd.
* src/wydawca.h (find_backup_file_name)
(create_hierarchy): Change signatures. All uses changed.
* tests/Makefile.am: Add new tests.
* tests/testsuite.at: Likewise.
(AT_WYDAWCA_DAEMON): Take additional argument.
* tests/inotify-rmsymlink.at: New test.
* tests/inotify-symlink.at: New test.
* tests/rmsymlink00.at: New test.
* tests/symlink00.at: New test.
* tests/symlink01.at: New test.
* tests/dist/rmsymlink.directive.asc: New directive file.
* tests/dist/symlink.directive.asc: New directive file.
Diffstat (limited to 'src/lock.c')
-rw-r--r-- | src/lock.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -269,7 +269,7 @@ wydawca_lock_init() if (enable_locking) { if (!lockdir) lockdir = grecs_strdup(LOCALSTATEDIR "/lock/" PACKAGE); - if (create_hierarchy(lockdir, 0)) + if (create_hierarchy(AT_FDCWD, lockdir)) exit(EX_OSFILE); } } |