[yast-commit] r67452 - /trunk/ruby-bindings/src/ruby/YRuby.cc
Author: jreidinger Date: Wed Feb 15 16:31:10 2012 New Revision: 67452 URL: http://svn.opensuse.org/viewcvs/yast?rev=67452&view=rev Log: fix memory leak in ruby bindings Modified: trunk/ruby-bindings/src/ruby/YRuby.cc Modified: trunk/ruby-bindings/src/ruby/YRuby.cc URL: http://svn.opensuse.org/viewcvs/yast/trunk/ruby-bindings/src/ruby/YRuby.cc?rev=67452&r1=67451&r2=67452&view=diff ============================================================================== --- trunk/ruby-bindings/src/ruby/YRuby.cc (original) +++ trunk/ruby-bindings/src/ruby/YRuby.cc Wed Feb 15 16:31:10 2012 @@ -242,6 +242,7 @@ char* tmp = fmtstr("%s\n\t%s", StringValuePtr(reason), StringValuePtr(backtrace)); y2error("%s.%s failed\n%s", module_name.c_str(), function.c_str(), tmp); + free(tmp); //workaround if last_exception failed, then return always string with message if(function == "last_exception") //TODO constantify last_exception { -- To unsubscribe, e-mail: yast-commit+unsubscribe@opensuse.org For additional commands, e-mail: yast-commit+help@opensuse.org
participants (1)
-
jreidinger@svn2.opensuse.org