[ 
https://issues.apache.org/jira/browse/PROTON-1300?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15484797#comment-15484797
 ] 

ASF subversion and git services commented on PROTON-1300:
---------------------------------------------------------

Commit eda1601deb560ccd9bd5a11f2442d86d37a4d517 in qpid-proton's branch 
refs/heads/master from Robert Gemmell
[ https://git-wip-us.apache.org/repos/asf?p=qpid-proton.git;h=eda1601 ]

PROTON-1300: remove redundant setLinkCredit(0) call to avoid minor confusion


> [proton-j] remove redundant credit update call
> ----------------------------------------------
>
>                 Key: PROTON-1300
>                 URL: https://issues.apache.org/jira/browse/PROTON-1300
>             Project: Qpid Proton
>          Issue Type: Task
>          Components: proton-j
>    Affects Versions: 0.14.0
>            Reporter: Robbie Gemmell
>            Assignee: Robbie Gemmell
>            Priority: Trivial
>             Fix For: 0.15.0
>
>
> In TransportImpl.processSenderFlow() there is a redundant call to update the 
> transportLink credit value to be 0 while draining the link,
> {noformat}
> transportLink.setLinkCredit(UnsignedInteger.valueOf(0));
> transportLink.setDeliveryCount(transportLink.getDeliveryCount().add(credits));
> transportLink.setLinkCredit(UnsignedInteger.ZERO);
> {noformat}
> These methods have no side effects, just simple setters/getters, and the same 
> value is set twice, so this change just avoids it looking odd.
> Credit [~tabish121] for spotting it :)



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to