diff options
author | Sébastien Helleu <flashcode@flashtux.org> | 2014-04-12 21:45:27 +0200 |
---|---|---|
committer | Sébastien Helleu <flashcode@flashtux.org> | 2014-04-12 21:45:27 +0200 |
commit | 001ea53f9de524bee480cdd3996b1c9e10b2d568 (patch) | |
tree | d5261592e646093e97c30e240cb2bb8418d0fc9d /src/plugins/relay | |
parent | 7618fdd240e32292b2202c76550c67f09ee0d90e (diff) | |
download | weechat-001ea53f9de524bee480cdd3996b1c9e10b2d568.zip |
core: fix crash on "weechat --upgrade" if no .upgrade files are found
Diffstat (limited to 'src/plugins/relay')
-rw-r--r-- | src/plugins/relay/relay-upgrade.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/plugins/relay/relay-upgrade.c b/src/plugins/relay/relay-upgrade.c index b6a94f511..f82854d07 100644 --- a/src/plugins/relay/relay-upgrade.c +++ b/src/plugins/relay/relay-upgrade.c @@ -240,6 +240,8 @@ relay_upgrade_load () relay_upgrade_set_buffer_callbacks (); upgrade_file = weechat_upgrade_new (RELAY_UPGRADE_FILENAME, 0); + if (!upgrade_file) + return 0; rc = weechat_upgrade_read (upgrade_file, &relay_upgrade_read_cb, NULL); weechat_upgrade_close (upgrade_file); |