<div dir="ltr"><div dir="ltr"><br></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Sat, May 9, 2020 at 3:50 PM roger <<a href="mailto:roger@beardandsandals.co.uk">roger@beardandsandals.co.uk</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Hi,<br>
<br>
I am debugging a problem witj ipv6 and endpoints. I would like to be <br>
able to examine a particular named endpoint when a breakpnt has been <br>
hit. So basically I need a single line of c code that calls a function <br>
(or nested functions) that take a endpoint name as a parameter and <br>
returns a pointer thta I can use in gdb print command.<br>
<br>
Any ideas gratefully received.<br>
<br></blockquote><div><br></div><div><font face="monospace">(gdb) </font>p *(struct ast_sip_endpoint *)ast_sorcery_retrieve_by_id(ast_sip_get_sorcery(), "endpoint", "1172")</div><div><br></div><div><font face="arial, sans-serif">or to save it to a variable...</font></div><div><font face="monospace"><br></font></div><div><font face="monospace">set $my_endpoint = ast_sorcery_retrieve_by_id(ast_sip_get_sorcery(), "endpoint", "1172")<br>(gdb) p *(struct ast_sip_endpoint *)$my_endpoint<br></font></div><div><font face="monospace"><br></font></div><div><font face="monospace"><br></font></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
Roger<br>
<br>
<br>
-- <br>
_____________________________________________________________________<br>
-- Bandwidth and Colocation Provided by <a href="http://www.api-digital.com" rel="noreferrer" target="_blank">http://www.api-digital.com</a> --<br>
<br>
asterisk-dev mailing list<br>
To UNSUBSCRIBE or update options visit:<br>
<a href="http://lists.digium.com/mailman/listinfo/asterisk-dev" rel="noreferrer" target="_blank">http://lists.digium.com/mailman/listinfo/asterisk-dev</a></blockquote></div><br clear="all"><div><br></div>-- <br><div dir="ltr" class="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr" style="font-size:12.8px"><div dir="ltr" style="font-size:12.8px"><div style="font-family:tahoma,sans-serif;font-size:small"><span style="color:rgb(7,55,99)">George Joseph</span><br></div></div><div dir="ltr" style="font-size:small"></div><div style="font-family:tahoma,sans-serif;font-size:small"><span style="color:rgb(7,55,99)">Asterisk Software Developer</span><br></div><span style="color:rgb(7,55,99);font-family:tahoma,sans-serif;font-size:small">direct/fax +1 256 428 6012</span><br><div style="font-family:tahoma,sans-serif;font-size:small"><font color="#073763" style="--darkreader-inline-color:#97cdf8;">Check us out at</font> <a href="http://www.sangoma.com/" style="color:rgb(17,85,204)" target="_blank">www.sangoma.com</a> and <a href="http://www.asterisk.org" target="_blank">www.asterisk.org</a><br></div><div style="font-family:tahoma,sans-serif;font-size:small"><img src="cid:ii_k3abte590" alt="image.png" width="184" height="32" style="margin-right: 0px;"></div></div></div></div></div></div></div></div></div>