diff options
author | Emmanuel Bouthenot <kolter@openics.org> | 2006-02-10 12:44:10 +0000 |
---|---|---|
committer | Emmanuel Bouthenot <kolter@openics.org> | 2006-02-10 12:44:10 +0000 |
commit | e4eeaaf1dd2fdfd0d62afd8a3f72cf09e89de542 (patch) | |
tree | 9e7548ba7da76f2b1c479d8c16368e0bcd8d37ef /src/plugins/scripts/ruby | |
parent | 4c34ac5d8f775782b89adaf796102eec7686c72c (diff) | |
download | weechat-e4eeaaf1dd2fdfd0d62afd8a3f72cf09e89de542.zip |
clean code to avoid warning and errors when compiling with gcc-2.95
Diffstat (limited to 'src/plugins/scripts/ruby')
-rw-r--r-- | src/plugins/scripts/ruby/weechat-ruby.c | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/src/plugins/scripts/ruby/weechat-ruby.c b/src/plugins/scripts/ruby/weechat-ruby.c index 275730b8f..4f014e7eb 100644 --- a/src/plugins/scripts/ruby/weechat-ruby.c +++ b/src/plugins/scripts/ruby/weechat-ruby.c @@ -99,7 +99,7 @@ rb_rescue_funcall (VALUE recv, VALUE func, int argc, ...) { va_list ap; - VALUE argv; + VALUE argv, ret; argv = rb_ary_new (); @@ -116,7 +116,7 @@ rb_rescue_funcall (VALUE recv, VALUE func, int argc, ...) va_end(ap); } - VALUE ret = rb_rescue(rb_funcall0, argv, rb_rescue0, func); + ret = rb_rescue(rb_funcall0, argv, rb_rescue0, func); if (NIL_P(ret)) ret = INT2FIX(PLUGIN_RC_KO); @@ -134,10 +134,10 @@ weechat_ruby_exec (t_weechat_plugin *plugin, t_plugin_script *script, char *function, char *server, char *arguments) { + VALUE ruby_retcode; + /* make gcc happy */ (void) plugin; - - VALUE ruby_retcode; ruby_current_script = script; @@ -1490,6 +1490,7 @@ weechat_ruby_cmd (t_weechat_plugin *plugin, int weechat_plugin_init (t_weechat_plugin *plugin) { + int ruby_error; char *weechat_ruby_code = { "class IO\n" @@ -1540,7 +1541,7 @@ weechat_plugin_init (t_weechat_plugin *plugin) "end\n" }; ruby_plugin = plugin; - int ruby_error = 0; + ruby_error = 0; plugin->printf_server (plugin, "Loading Ruby module \"weechat\""); |