C-Netz: Move callref to transaction. Callref on SpK only when its busy.
Only when busy, the channel has callref. This is required for audio routing. During setup, the callref assigned to transaction and kept there until release to/from upper layer.
This commit is contained in:
@@ -162,6 +162,25 @@ transaction_t *search_transaction_number(cnetz_t *cnetz, uint8_t futln_nat, uint
|
||||
return NULL;
|
||||
}
|
||||
|
||||
transaction_t *search_transaction_callref(cnetz_t *cnetz, int callref)
|
||||
{
|
||||
transaction_t *trans = cnetz->trans_list;
|
||||
|
||||
/* just in case, this should not happen */
|
||||
if (!callref)
|
||||
return NULL;
|
||||
while (trans) {
|
||||
if (trans->callref == callref) {
|
||||
const char *rufnummer = transaction2rufnummer(trans);
|
||||
PDEBUG(DTRANS, DEBUG_DEBUG, "Found transaction for subscriber '%s'\n", rufnummer);
|
||||
return trans;
|
||||
}
|
||||
trans = trans->next;
|
||||
}
|
||||
|
||||
return NULL;
|
||||
}
|
||||
|
||||
static const char *trans_state_name(int state)
|
||||
{
|
||||
switch (state) {
|
||||
|
Reference in New Issue
Block a user