mirror of
https://github.com/weechat/weechat.git
synced 2026-07-08 18:53:12 +02:00
core, irc, xfer: display more information in memory allocation errors (issue #573)
This commit is contained in:
@@ -620,8 +620,9 @@ xfer_network_connect_chat_recv_cb (const void *pointer, void *data,
|
||||
break;
|
||||
case WEECHAT_HOOK_CONNECT_MEMORY_ERROR:
|
||||
weechat_printf (NULL,
|
||||
_("%s%s: not enough memory"),
|
||||
weechat_prefix ("error"), XFER_PLUGIN_NAME);
|
||||
_("%s%s: not enough memory (%s)"),
|
||||
weechat_prefix ("error"), XFER_PLUGIN_NAME,
|
||||
(error) ? error : "-");
|
||||
break;
|
||||
case WEECHAT_HOOK_CONNECT_TIMEOUT:
|
||||
weechat_printf (NULL,
|
||||
|
||||
@@ -1119,16 +1119,18 @@ xfer_add_cb (const void *pointer, void *data,
|
||||
if (!path)
|
||||
{
|
||||
weechat_printf (NULL,
|
||||
_("%s%s: not enough memory"),
|
||||
weechat_prefix ("error"), XFER_PLUGIN_NAME);
|
||||
_("%s%s: not enough memory (%s)"),
|
||||
weechat_prefix ("error"), XFER_PLUGIN_NAME,
|
||||
"xfer_add, path");
|
||||
goto error;
|
||||
}
|
||||
filename2 = malloc (strlen (path) + strlen (filename) + 4);
|
||||
if (!filename2)
|
||||
{
|
||||
weechat_printf (NULL,
|
||||
_("%s%s: not enough memory"),
|
||||
weechat_prefix ("error"), XFER_PLUGIN_NAME);
|
||||
_("%s%s: not enough memory (%s)"),
|
||||
weechat_prefix ("error"), XFER_PLUGIN_NAME,
|
||||
"xfer_add, filename2");
|
||||
free (path);
|
||||
goto error;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user