@ -6959,7 +6959,9 @@ retryowner:
check_provisioning ( & sin , fd , ies . serviceident , ies . provver ) ;
check_provisioning ( & sin , fd , ies . serviceident , ies . provver ) ;
/* If we're in trunk mode, do it now, and update the trunk number in our frame before continuing */
/* If we're in trunk mode, do it now, and update the trunk number in our frame before continuing */
if ( ast_test_flag ( iaxs [ fr - > callno ] , IAX_TRUNK ) ) {
if ( ast_test_flag ( iaxs [ fr - > callno ] , IAX_TRUNK ) ) {
fr - > callno = make_trunk ( fr - > callno , 1 ) ;
int new_callno ;
if ( ( new_callno = make_trunk ( fr - > callno , 1 ) ) ! = - 1 )
fr - > callno = new_callno ;
}
}
/* For security, always ack immediately */
/* For security, always ack immediately */
if ( delayreject )
if ( delayreject )
@ -8072,8 +8074,11 @@ static struct ast_channel *iax2_request(const char *type, int format, void *data
/* If this is a trunk, update it now */
/* If this is a trunk, update it now */
ast_copy_flags ( iaxs [ callno ] , & cai , IAX_TRUNK | IAX_SENDANI | IAX_NOTRANSFER | IAX_USEJITTERBUF | IAX_FORCEJITTERBUF ) ;
ast_copy_flags ( iaxs [ callno ] , & cai , IAX_TRUNK | IAX_SENDANI | IAX_NOTRANSFER | IAX_USEJITTERBUF | IAX_FORCEJITTERBUF ) ;
if ( ast_test_flag ( & cai , IAX_TRUNK ) )
if ( ast_test_flag ( & cai , IAX_TRUNK ) ) {
callno = make_trunk ( callno , 1 ) ;
int new_callno ;
if ( ( new_callno = make_trunk ( callno , 1 ) ) ! = - 1 )
callno = new_callno ;
}
iaxs [ callno ] - > maxtime = cai . maxtime ;
iaxs [ callno ] - > maxtime = cai . maxtime ;
if ( cai . found )
if ( cai . found )
ast_copy_string ( iaxs [ callno ] - > host , pds . peer , sizeof ( iaxs [ callno ] - > host ) ) ;
ast_copy_string ( iaxs [ callno ] - > host , pds . peer , sizeof ( iaxs [ callno ] - > host ) ) ;