diff options
author | mattf <mattf@f38db490-d61c-443f-a65b-d21fe96a405b> | 2005-05-23 17:07:32 +0000 |
---|---|---|
committer | mattf <mattf@f38db490-d61c-443f-a65b-d21fe96a405b> | 2005-05-23 17:07:32 +0000 |
commit | 5a1a8b26d9b61ef0b357d43bf2e883a4f4bb684a (patch) | |
tree | 4517bca04eb29d2c648d37db12d44c5392e1a41a /channels | |
parent | 561ca6ce2be355771959c337f40344185139cab6 (diff) |
Bug in pri_find_principle
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@5755 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'channels')
-rwxr-xr-x | channels/chan_zap.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/channels/chan_zap.c b/channels/chan_zap.c index f90b48a09..de9f0f4c1 100755 --- a/channels/chan_zap.c +++ b/channels/chan_zap.c @@ -7337,7 +7337,9 @@ static int pri_find_principle(struct zt_pri *pri, int channel) if (!PRI_EXPLICIT(channel)) { spanfd = pri_active_dchan_fd(pri); - span = ioctl(spanfd, ZT_GET_PARAMS, ¶m); + if (ioctl(spanfd, ZT_GET_PARAMS, ¶m)) + return -1; + span = param.spanno - 1; } for (x=0;x<pri->numchans;x++) { |