Commit 8a665d15 authored by Thomas Roessler's avatar Thomas Roessler

Don't use curses when we don't have it.

parent f156fe38
......@@ -106,7 +106,8 @@ static int dotlock_file (const char *path, int retry)
retry_lock:
mutt_clear_error();
if((r = invoke_dotlock(path, flags, retry)) == DL_EX_EXIST)
if((r = invoke_dotlock(path, flags, retry)) == DL_EX_EXIST
&& !option (OPTNOCURSES))
{
char msg[LONG_STRING];
......@@ -118,6 +119,10 @@ retry_lock:
retry--;
goto retry_lock;
}
}
else if (option (OPTNOCURSES))
{
mutt_error ( _("Can't dotlock %s.\n"), path);
}
return (r == DL_EX_OK ? 0 : -1);
}
......
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