diff options
author | mmichelson <mmichelson@f38db490-d61c-443f-a65b-d21fe96a405b> | 2009-01-21 00:33:32 +0000 |
---|---|---|
committer | mmichelson <mmichelson@f38db490-d61c-443f-a65b-d21fe96a405b> | 2009-01-21 00:33:32 +0000 |
commit | 0c9ed7bb4f034a34c796c8de512e41a6a02f617e (patch) | |
tree | a97f6173d8fc9f44674ddf3b1cf1673855a869d8 /apps/app_queue.c | |
parent | 5d41434a2489c119060efa509c34b937b9942ffe (diff) |
Fix device state parsing issues for channel names with multiple slashes
The fix being applied is a bit different for trunk and the 1.6.X branches.
For trunk, we only wish to strip off the characters beyond the second slash
if the channel is a Local channel (i.e. we are removing the /n from the device
name). Other channel technologies with multiple slashes (e.g. DAHDI) need the
information after the second slash in order to get the proper device state
information.
In addition to this fix, the 1.6.X branches are receiving a much more important
fix as well. The problem in 1.6.X is that the member's device name was being directly
changed instead of having a copy changed. This meant that we would strip off the
second slash and trailing characters and then leave the member's device name like
that permanently thereafter.
(closes issue #14014)
Reported by: kebl0155
Patches:
14014_number2.patch uploaded by putnopvut (license 60)
Tested by: kebl0155
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@169611 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'apps/app_queue.c')
-rw-r--r-- | apps/app_queue.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/apps/app_queue.c b/apps/app_queue.c index 444f0fc52..4237350a2 100644 --- a/apps/app_queue.c +++ b/apps/app_queue.c @@ -1032,7 +1032,7 @@ static int handle_statechange(void *datap) ast_copy_string(interface, m->state_interface, sizeof(interface)); if ((slash_pos = strchr(interface, '/'))) - if ((slash_pos = strchr(slash_pos + 1, '/'))) + if (!strncasecmp(interface, "Local/", 6) && (slash_pos = strchr(slash_pos + 1, '/'))) *slash_pos = '\0'; if (!strcasecmp(interface, sc->dev)) { |