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

ASF GitHub Bot commented on DISPATCH-1234:
------------------------------------------

kgiusti commented on pull request #433: DISPATCH-1234 - Zero out the edge 
context on the link before the edge…
URL: https://github.com/apache/qpid-dispatch/pull/433#discussion_r245089295
 
 

 ##########
 File path: src/router_core/modules/edge_addr_tracking/edge_addr_tracking.c
 ##########
 @@ -308,13 +316,20 @@ static void on_link_event(void *context, qdrc_event_t 
event, qdr_link_t *link)
             if (addr && qdr_address_is_mobile_CT(addr)) {
                 qdr_addr_endpoint_state_t *endpoint_state = 
qdrc_get_endpoint_state_for_connection(mc->endpoint_state_list, link->conn, 
link);
                 link->edge_context = endpoint_state;
+                endpoint_state->link = link;
 
                 if (qdrc_can_send_address(addr, link->conn) && endpoint_state) 
{
                     qdrc_send_message(mc->core, addr, 
endpoint_state->endpoint, true);
                 }
             }
             break;
         }
+        case QDRC_EVENT_LINK_EDGE_DATA_DETACHED :
+        {
+            link->edge_context = 0;
 
 Review comment:
   should the corresponding endpoint_state->link be reset also?
 
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


> Router crash when edge tracking address handler tries to access freed endpoint
> ------------------------------------------------------------------------------
>
>                 Key: DISPATCH-1234
>                 URL: https://issues.apache.org/jira/browse/DISPATCH-1234
>             Project: Qpid Dispatch
>          Issue Type: Bug
>          Components: Container
>            Reporter: Ganesh Murthy
>            Assignee: Ganesh Murthy
>            Priority: Major
>             Fix For: 1.5.0
>
>
> {noformat}
> (gdb) bt
> #0  0x0000000004e3d53f in raise () from /lib64/libc.so.6
> #1  0x0000000004e27895 in abort () from /lib64/libc.so.6
> #2  0x0000000004e27769 in __assert_fail_base.cold.0 () from /lib64/libc.so.6
> #3  0x0000000004e359f6 in __assert_fail () from /lib64/libc.so.6
> #4  0x00000000048bc8d1 in on_addr_event (context=0x153a5e20, event=524288, 
> addr=0x141158f0) at 
> /home/gmurthy/opensource/qpid-dispatch/src/router_core/modules/edge_addr_tracking/edge_addr_tracking.c:242
> #5  0x000000000489cbf0 in qdrc_event_addr_raise (core=0x15395d30, 
> event=524288, addr=0x141158f0) at 
> /home/gmurthy/opensource/qpid-dispatch/src/router_core/core_events.c:114
> #6  0x00000000048ac5e3 in qdr_core_unbind_address_link_CT (core=0x15395d30, 
> addr=0x141158f0, link=0x1410fda0) at 
> /home/gmurthy/opensource/qpid-dispatch/src/router_core/router_core.c:504
> #7  0x000000000489c110 in qdr_link_inbound_detach_CT (core=0x15395d30, 
> action=0x13c411c0, discard=false) at 
> /home/gmurthy/opensource/qpid-dispatch/src/router_core/connections.c:1642
> #8  0x00000000048add55 in router_core_thread (arg=0x15395d30) at 
> /home/gmurthy/opensource/qpid-dispatch/src/router_core/router_core_thread.c:124
> #9  0x000000000496458e in start_thread () from /lib64/libpthread.so.0
> #10 0x0000000004f026a3 in clone () from /lib64/libc.so.6
> (gdb){noformat}



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@qpid.apache.org
For additional commands, e-mail: dev-h...@qpid.apache.org

Reply via email to