Revert introduction of minor memory leak in Ruby wrappers

This commit is contained in:
William S Fulton 2016-05-17 20:04:24 +01:00
commit 1330337491

View file

@ -2136,7 +2136,11 @@ public:
String *protoTypes = NewString("");
do {
Append( protoTypes, "\n\" ");
if ( !isCtor ) Printv( protoTypes, SwigType_str(Getattr(sibl,"type"), NULL), " ", NIL );
if (!isCtor) {
SwigType *type = SwigType_str(Getattr(sibl, "type"), NULL);
Printv(protoTypes, type, " ", NIL);
Delete(type);
}
Printv(protoTypes, methodName, NIL );
Parm* p = Getattr(sibl, "wrap:parms");
if (p && (current == MEMBER_FUNC || current == MEMBER_VAR ||