diff options
Diffstat (limited to 'lib/gitano/usercommand.lua')
-rw-r--r-- | lib/gitano/usercommand.lua | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/gitano/usercommand.lua b/lib/gitano/usercommand.lua index 5d3d7ac..af7141c 100644 --- a/lib/gitano/usercommand.lua +++ b/lib/gitano/usercommand.lua @@ -282,6 +282,7 @@ end local function update_htpasswd(user, passwd) local htpasswd_path = os.getenv("HOME") .. "/htpasswd" + local lock = util.lockfile(htpasswd_path .. ".lock") local flags = io.open(htpasswd_path, "r") and "-i" or "-ic" local exit_code @@ -303,7 +304,7 @@ local function update_htpasswd(user, passwd) _, exit_code = proc:wait() end - + util.unlockfile(lock) return exit_code == 0 end |