Skip to content

Commit

Permalink
Fix for RestComm#339
Browse files Browse the repository at this point in the history
  • Loading branch information
hmacias-avaya committed Sep 12, 2017
1 parent 1465420 commit a42001c
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -206,7 +206,7 @@ public void cancel(String[] protocol, int[] reasonCode, String[] reasonText) {
if(logger.isDebugEnabled()) {
logger.debug("Trying to cancel ProxyBranch for outgoing request " + outgoingRequest);
}
if(lastResponse.getStatus() > Response.OK && !recursedBranches.isEmpty()) {
if(lastResponse.getStatus() > Response.OK && recursedBranches != null && !recursedBranches.isEmpty()) {
// Javadoc says it should throw an java.lang.IllegalStateException if the transaction has already been completed and it has no child branches
if(logger.isDebugEnabled()) {
logger.debug("lastResponse status for this branch is " + lastResponse.getStatus() + " and it has " + recursedBranches.size() + " to cancel");
Expand Down

0 comments on commit a42001c

Please sign in to comment.