xfer: make file transfer fail when option xfer.file.auto_rename is off and file already exists (closes #1633)

This commit is contained in:
Sébastien Helleu 2021-04-26 20:51:17 +02:00
parent bcd889cf90
commit 9f0e7fb47e
2 changed files with 2 additions and 1 deletions

View File

@ -32,6 +32,7 @@ Bug fixes::
* core: prevent switching to start of visited buffers when jumping to next (issue #1591, issue #1592)
* core: recreate buflist and fset bars on /reload when WeeChat is started without configuration files (issue #1618)
* buflist: fix comparison of hotlists in option buflist.look.sort (issue #1621)
* xfer: make file transfer fail when option xfer.file.auto_rename is off and file already exists (issue #1633)
Tests::

View File

@ -185,7 +185,7 @@ xfer_file_find_suffix (struct t_xfer *xfer)
return;
/* if auto rename is not set, then abort xfer */
if (!xfer_config_file_auto_rename)
if (!weechat_config_boolean (xfer_config_file_auto_rename))
{
xfer_close (xfer, XFER_STATUS_FAILED);
xfer_buffer_refresh (WEECHAT_HOTLIST_MESSAGE);