Commit d60e9f4e authored by Leigh B Stoller's avatar Leigh B Stoller

Another tweak to try to avoid uuid generation race. Just a stab in the

dark.
parent 5ae92284
......@@ -158,6 +158,10 @@ if (@ARGV < 1) {
my $orgunit = shift(@ARGV);
my $uuid = (@ARGV ? shift(@ARGV) : undef);
# Moved before uuid generation. Might be a race, might not.
TBScriptLock("mkusercert") == 0 or
fatal("Could not get the lock!");
# Generate/confirm uuid
if (!defined($uuid)) {
$uuid = NewUUID();
......@@ -176,9 +180,6 @@ if (!defined($email)) {
chdir("$WORKDIR") or
fatal("Could not chdir to $WORKDIR: $!");
TBScriptLock("mkusercert") == 0 or
fatal("Could not get the lock!");
#
# Need an index file, which is the openssl version of the DB.
#
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment