Github user ted-ross commented on a diff in the pull request:

    https://github.com/apache/qpid-dispatch/pull/167#discussion_r122777702
  
    --- Diff: src/router_core/forwarder.c ---
    @@ -101,33 +101,26 @@ static void 
qdr_forward_find_closest_remotes_CT(qdr_core_t *core, qdr_address_t
     
     qdr_delivery_t *qdr_forward_new_delivery_CT(qdr_core_t *core, 
qdr_delivery_t *in_dlv, qdr_link_t *link, qd_message_t *msg)
     {
    -    qdr_delivery_t *dlv = new_qdr_delivery_t();
    -    uint64_t       *tag = (uint64_t*) dlv->tag;
    -
    -    ZERO(dlv);
    -    sys_atomic_init(&dlv->ref_count, 0);
    -    dlv->link       = link;
    -    dlv->msg        = qd_message_copy(msg);
    -    dlv->settled    = !in_dlv || in_dlv->settled;
    -    dlv->presettled = dlv->settled;
    +    qdr_delivery_t *out_dlv = new_qdr_delivery_t();
    +    uint64_t       *tag = (uint64_t*) out_dlv->tag;
    +
    +    ZERO(out_dlv);
    +    sys_atomic_init(&out_dlv->ref_count, 0);
    +    out_dlv->link       = link;
    +    out_dlv->msg        = qd_message_copy(msg);
    +    out_dlv->settled    = !in_dlv || in_dlv->settled;
    +    out_dlv->presettled = out_dlv->settled;
         *tag            = core->next_tag++;
    -    dlv->tag_length = 8;
    -    dlv->error      = 0;
    +    out_dlv->tag_length = 8;
    +    out_dlv->error      = 0;
     
         //
    -    // Create peer linkage only if the delivery is not settled
    +    // Create peer linkage only if the outgoing delivery is not settled
         //
    -    if (!dlv->settled) {
    -        if (in_dlv && in_dlv->peer == 0) {
    --- End diff --
    
    You've lost the in_dlv->peer == 0 check


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

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

Reply via email to