[ 
https://issues.apache.org/jira/browse/THRIFT-4192?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

James E. King, III resolved THRIFT-4192.
----------------------------------------
    Resolution: Duplicate
      Assignee: James E. King, III

> Generated java async code generates a result structure that is unused 
> (Coverity)
> --------------------------------------------------------------------------------
>
>                 Key: THRIFT-4192
>                 URL: https://issues.apache.org/jira/browse/THRIFT-4192
>             Project: Thrift
>          Issue Type: Bug
>          Components: Java - Compiler
>    Affects Versions: 0.10.0
>            Reporter: James E. King, III
>            Assignee: James E. King, III
>            Priority: Trivial
>
> The async method generator for Java emits an onError handler which contains 
> this pattern:
> {noformat}
>          public void onError(java.lang.Exception e) {
> 1556            byte msgType = org.apache.thrift.protocol.TMessageType.REPLY;
> 1557            org.apache.thrift.TSerializable msg;
>     CID 26029 (#1 of 1): DLS: Dead local store (FB.DLS_DEAD_LOCAL_STORE)1. 
> defect: Dead store to result.
> 1558            Delete_Bundle_Request_Data_result result = new 
> Delete_Bundle_Request_Data_result();
> 1559            if (e instanceof 
> org.apache.thrift.transport.TTransportException) {
> 1560              _LOGGER.error("TTransportException inside handler", e);
> 1561              fb.close();
> 1562              return;
> 1563            } else if (e instanceof 
> org.apache.thrift.TApplicationException) {
> {noformat}
> The item on line 1558 is not used.  Any call method in a service definition 
> will cause this.



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Reply via email to