<div dir="ltr"><div>Hello,</div><div><br></div><div>With Debian Buster's Asterisk 16.2.1, please consider the following dialplan</div><div>;Case A<br></div><div>;exten = 29,1,Dial(PJSIP/${EXTEN})</div><div>;Case B</div><div>;exten = 29,1,Gosub(foo,${EXTEN},1)</div><div>;Case C</div><div>exten = 29,1,Gosub(bar,s,1(${EXTEN}))</div><div><br></div><div>[foo]<br>exten = _X.,1,Dial(PJSIP/${EXTEN})<br>same = n,Return()<br><br>[bar]<br>exten = s,1,Set(TGT=${ARG1})<br>same = n,Dial(PJSIP/${TGT})<br>same = n,Return()</div><div><br></div><div>When running case A et B, dialing phone gets a Ringing signal from Asterisk with a P-Asserted-Id</div><div>header set to 29: this is expected.</div><div><br></div><div>When running case C, dialing phone gets a Ringing signal from Asterisk with a P-Asserted-Id<div>header set to s: this is not what I expected.</div><div><br></div><div><br></div><div>Thoughts ?</div><div>Is there a way to work around this without using pattern B above ?</div><div><br></div><div>Best regards<br></div></div></div>