mirror of
https://github.com/weechat/weechat.git
synced 2026-07-05 09:13:14 +02:00
scripts: reset current script pointer when load of script fails in python/perl/ruby/lua/tcl plugins
This commit is contained in:
@@ -595,11 +595,12 @@ weechat_ruby_load (const char *filename)
|
||||
err = rb_gv_get("$!");
|
||||
weechat_ruby_print_exception(err);
|
||||
|
||||
if (ruby_current_script != NULL)
|
||||
if (ruby_current_script)
|
||||
{
|
||||
plugin_script_remove (weechat_ruby_plugin,
|
||||
&ruby_scripts, &last_ruby_script,
|
||||
ruby_current_script);
|
||||
ruby_current_script = NULL;
|
||||
}
|
||||
|
||||
return 0;
|
||||
|
||||
Reference in New Issue
Block a user