You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@thrift.apache.org by GitBox <gi...@apache.org> on 2021/04/08 22:26:05 UTC

[GitHub] [thrift] Jens-G commented on a change in pull request #2369: Abnormal Branch Memory Leak

Jens-G commented on a change in pull request #2369:
URL: https://github.com/apache/thrift/pull/2369#discussion_r610159473



##########
File path: compiler/cpp/src/thrift/generate/t_c_glib_generator.cc
##########
@@ -4061,8 +4061,17 @@ void t_c_glib_generator::generate_deserialize_field(ostream& out,
       throw "compiler error: no C reader for base type " + t_base_type::t_base_name(tbase) + name;
     }
     out << ", error)) < 0)" << endl;
-    out << indent() << "  return " << error_ret << ";" << endl << indent() << "xfer += ret;"
-        << endl;
+    if ((tbase != t_base_type::TYPE_STRING) && allocate) {

Review comment:
       Why is that test different to line 4022 (allocate is not tested there)? Shouldn't that be consistent?




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org