Summary:ASTERISK-12957: Default delimiter for ${CUT(var,,n)} is no longer handled
Reporter:John Covert (jcovert)Labels:
Date Opened:2008-10-23 06:59:04Date Closed:2008-10-30 13:56:16
Versions:Frequency of
Description:The default delimiter for CUT is supposed to be a "-" (as documented in show function).

Any existing dialplan will malfunction until this is fixed.


Example (shortened output):

fails if delimiter not specified (default not taken).

NoOp("..", "CUT(foo,,1) returns one-two")
NoOp("..", "CUT(foo,-,1) returns one")

Seen in
Comments:By: Jason Parker (jparker) 2008-10-27 12:27:45

I'm not able to reproduce this..

Can you show us the exact dialplan you're using?

By: Alec Davis (alecdavis) 2008-10-27 21:58:21

I reported similar problem with asterisk 1.6.0rc6
refer http://bugs.digium.com/view.php?id=13470

By: Tilghman Lesher (tilghman) 2008-10-28 10:39:10

jcovert:  please update to SVN branch 1.6.0.  This was probably already fixed.

By: John Covert (jcovert) 2008-10-28 11:01:21

I am running release, not the release candidate.

Asterisk built by root @ JRCovert.local on a Power Macintosh running Darwin on 2008-10-23 02:02:13 UTC

The dialplan which produced the output above is:

exten => 999,1,Noop(Test of CUT function default delimiter)
exten => 999,n,Set(foo="one-two")
exten => 999,n,Noop(CUT(foo,,1) returns ${CUT(foo,,1)})
exten => 999,n,Noop(CUT(foo,-,1) returns ${CUT(foo,-,1)})
exten => 999,n,Hangup

By: Tilghman Lesher (tilghman) 2008-10-28 11:50:09

jcovert:  The point was that is a snapshot and will never be changed.  The SVN 1.6.0 branch is what will become and may contain the fix.  We need you to verify that the fix is there.

By: John Covert (jcovert) 2008-10-30 13:31:13

OK, I have loaded the latest from SVN.

Problem was fixed after

Please close this and the duplicate.