Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
openSUSE:Backports:SLE-15-SP6
dirvish
dirvish-lock-vault-against-overlapping-runs.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File dirvish-lock-vault-against-overlapping-runs.patch of Package dirvish
diff --git a/dirvish.pl b/dirvish.pl index c2488c4..5a6a0b6 100644 --- a/dirvish.pl +++ b/dirvish.pl @@ -451,6 +451,18 @@ scalar @{$$Options{exclude}} if (!$$Options{'no-run'}) { + $lock_file = "$vault/dirvish/lock_file"; + if (! -f $lock_file) + { + open(LOCK, "+>", $lock_file) or seppuku 150, "cannot create $lock_file"; + printf LOCK $$; + close(LOCK); + } + else + { + seppuku 151, "$lock_file already exists"; + } + mkdir "$vault/$image", 0700 or seppuku 230, "mkdir $vault/$image failed"; mkdir $destree, 0755; @@ -755,6 +767,8 @@ if ($$Options{'post-server'}) } } +unlink($lock_file); + if($status{fatal}) { system ("rm -rf $destree");
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor