Commit 46b0f620 authored by Per Cederqvist's avatar Per Cederqvist
Browse files

(lock_db): Clarify log messages.

parent c8307925
......@@ -97,7 +97,7 @@ int lock_db(void)
{
if (new_lock[ix] != current_lock[ix])
{
kom_log("Database locked by %s\n", current_lock);
kom_log("Database already locked by %s\n", current_lock);
return -1;
}
......@@ -107,12 +107,12 @@ int lock_db(void)
pid = strtol(&current_lock[ix+1], &end, 10);
if (end == &current_lock[ix+1])
restart_kom("Broken lock symlink %s: %s\n",
restart_kom("Found a broken lock symlink %s: %s\n",
param.lockfile_name, current_lock);
if (kill(pid, 0) == 0 || errno != ESRCH)
{
kom_log("Database locked by %s\n", current_lock);
kom_log("Database already locked by %s\n", current_lock);
return -1;
}
......@@ -122,7 +122,7 @@ int lock_db(void)
restart_kom("Failed to remove stale lock symlink %s\n",
param.lockfile_name);
else
kom_log("Stale lock file left by %s removed.\n", current_lock);
kom_log("Removed stale lock file left by %s.\n", current_lock);
}
restart_kom("Unreachable code reached in lock_db.\n");
}
......
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