From: Jens Geyer Date: Thu, 20 Mar 2014 21:03:48 +0000 (+0200) Subject: THRIFT-2418 Go handler function panics on internal error X-Git-Url: https://source.supwisdom.com/gerrit/gitweb?a=commitdiff_plain;h=3c489f9e7fbef6d3a169fa585b7f244bca1a3be5;p=common%2Fthrift.git THRIFT-2418 Go handler function panics on internal error Patch: Frank Schroeder --- diff --git a/compiler/cpp/src/generate/t_go_generator.cc b/compiler/cpp/src/generate/t_go_generator.cc index dadef5c0..168ca88a 100644 --- a/compiler/cpp/src/generate/t_go_generator.cc +++ b/compiler/cpp/src/generate/t_go_generator.cc @@ -2369,7 +2369,7 @@ void t_go_generator::generate_process_function(t_service* tservice, } f_service_ << - indent() << " x := thrift.NewTApplicationException(thrift.INTERNAL_ERROR, \"Internal error processing " << escape_string(tfunction->get_name()) << ": \" + err.Error())" << endl << + indent() << " x := thrift.NewTApplicationException(thrift.INTERNAL_ERROR, \"Internal error processing " << escape_string(tfunction->get_name()) << ": \" + err2.Error())" << endl << indent() << " oprot.WriteMessageBegin(\"" << escape_string(tfunction->get_name()) << "\", thrift.EXCEPTION, seqId)" << endl << indent() << " x.Write(oprot)" << endl << indent() << " oprot.WriteMessageEnd()" << endl <<