Files
storeBackup/fix-tmp-lock-file-race-condition.patch
Martin Pluskal c8c0581f6d Accepting request 1150475 from home:amanzini:branches:Archiving:Backup
- Update to 3.5.2
        storeBackup.pl
        - option --maxHardLinks was not configurable in the
          configuration file
        - pipe buffering was changed to new needs since
          about kernel 5.13 (relevant only if you backup devices)
        storeBackupRecover.pl
        - restoring of devices (eg. sda) didn't work because of
          bug in option checkDevicesDir0 in storeBackup.pl when
          using more than one directory level like "Devs/Sticks"
        storeBackupUpdateBackup.pl
        - added log file entry about number of WARNINGs and
          ERRORs happend (like at storeBackup.pl)
- update to 3.5.1
        storeBackup.pl
        - linkToRecent didn't work when used for the very first time
          in a series
        - added option suppressInfo with key readCheckSums
        - changed the order of execution:
          write backup -> sync -> write 'finished' -> write linkToRecent
          -> delete old backups -> start postcommand
        storeBackupMergeIsolatedBackup.pl
        - added option --move
        storeBackupSearch.pl
        - option 'backupDir' didn't work (normally not needed)
        lib/fileDir.pl
        - more detailed error messages when copying of a file does
          not succeed
        lib/checkParam2.pl
        - overwriting settings from config file via commandline didn't

OBS-URL: https://build.opensuse.org/request/show/1150475
OBS-URL: https://build.opensuse.org/package/show/Archiving:Backup/storeBackup?expand=0&rev=15
2024-02-25 16:41:10 +00:00

23 lines
707 B
Diff

Index: storeBackup/lib/fileDir.pl
===================================================================
--- storeBackup.orig/lib/fileDir.pl
+++ storeBackup/lib/fileDir.pl
@@ -21,7 +21,7 @@
use Digest::MD5 qw(md5_hex);
-use Fcntl qw(O_RDWR O_CREAT);
+use Fcntl qw(O_RDWR O_CREAT O_WRONLY O_EXCL);
use Fcntl ':mode';
use POSIX;
use Cwd 'abs_path';
@@ -493,7 +493,7 @@ sub checkLockFile
'-str' => ["creating lock file <$lockFile>"]);
&::checkDelSymLink($lockFile, $prLog, 0x01);
- open(FILE, '>', $lockFile) or
+ sysopen(FILE, $lockFile, O_WRONLY | O_CREAT | O_EXCL) or
$prLog->print('-kind' => 'E',
'-str' => ["cannot create lock file <$lockFile>"],
'-exit' => 1);