app_chanisavail.c: Simplify dialplan using ChanIsAvail.

Dialplan has to be careful about passing an empty device list or empty
positions in the list.  As a result, dialplan has to check for these
conditions before using ChanIsAvail.  Simplify dialplan by making
ChanIsAvail handle these conditions gracefully.

* Made tolerate empty positions in the device list.

* Simplified the code and eliminated some unnecessary indention.

ASTERISK-28638

Change-Id: I9e4b67e2cbf26b2417c2d03485b8568e898931d3
This commit is contained in:
Richard Mudgett
2019-12-30 13:13:46 -06:00
parent 3818759e9c
commit a7692ce2f4
2 changed files with 79 additions and 69 deletions

View File

@@ -0,0 +1,5 @@
Subject: app_chanisavail
The ChanIsAvail application now tolerates empty positions in the supplied
device list. Dialplan can now be simplified by not having to check for
empty positions in the device list.