Should I report Errors.?

Quick bit of advice if possible.
I found a silly error in the dialplan [macro-dial-one] .

VERBOSE[3169] pbx.c: – Executing [s@macro-dial-one:41] Set(“Local/2000@from-queue-000000d7;2”, “D_OPTIONS=TtrM(auto-blkvm)I”)
VERBOSE[3169] pbx.c: – Executing [s@macro-dialout-one-predial-hook:1] MacroExit(“Local/2000@from-queue-000000d7;2”, “”)
ERROR[3169] pbx.c: Function STRREPLACE not registered
VERBOSE[3169] pbx.c: – Executing [s@macro-dial-one:43] ExecIf(“Local/2000@from-queue-000000d7;2”, “0?Set(D_OPTIONS=I)”)
ERROR[3169] pbx.c: Function STRREPLACE not registered
VERBOSE[3169] pbx.c: – Executing [s@macro-dial-one:44] Dial(“Local/2000@from-queue-000000d7;2”, “SIP/2000,60,TtrM(auto-blkvm)I”)

the reason I ask if I should report it is my freepbx / Asterisk is not the latest
12.0.76.2 with 11.19.0 is one box
12.0.76.2 with 1.8.32.3 is the old test rig
12.0.76.2 with 11.17.1 on another.

they all share the same “STRREPLACE” in the dialplan
but not sure if they all produce an error as different units are not studied as much.

Any thoughts.?

Hv.

No

can only be an artifact of yourself.

That part is fine !!

the STRREPLACE error is in [macro-dial-one]

[godial] 43. Macro(dialout-one-predial-hook,) [pbx_config]

                44. ExecIf($["${DIRECTION}" = "INBOUND"]?Set(D_OPTIONS=${STRREPLACE(D_OPTIONS,T)}I)) [pbx_config]

                45. Dial(${DSTRING},${ARG1},${D_OPTIONS})     [pbx_config] 

Hv.

If you say so, the asterisk dialplan disagrees

https://wiki.asterisk.org/wiki/display/AST/Asterisk+11+Function_STRREPLACE

D_OPTIONS is not a string, it is a null

Yep it is in there alright,
I did see some other uses of Replace() so thought STRREPLACE() may have been replaced !!

I must have shot it in the head with all my text editing.
But none of the dial-one stuff is mine.

Gonna have to test another box now.

Hv.

but surely your

IS, no?

https://wiki.asterisk.org/wiki/display/AST/Manipulating+Variables+Basics

https://wiki.asterisk.org/wiki/display/AST/Selecting+Characters+from+Variables

D_OPTIONS is a variable set in FreePBX you refer to that string a ${D_OPTIONS}

No is No.

[ Context ‘macro-dialout-one-predial-hook’ created by ‘pbx_config’ ]

‘s’ => 1. MacroExit() [pbx_config]

-= 1 extension (1 priority) in 1 context. =-

I use predial stuff in other environments (callerid lookup on outbound calls)
But this one is just bare in that department

Odd hey.

Hv.

see my previous edit

:slight_smile:
I don’t refer to anything,
This is raw Freepbx handy work.

Has me puzzled but not enough to loose sleep. :thinking:

Hv.

No you don’t, but you TRY and refer to it here

but it won’t work and you are missing a comma . . .

No No…

I don’t

Seriously that is RAW FreePbx Text unedited by me.
The only way it would have been created is by someone else’s fingers or mindwork.

I only refer to it to assist in pointing out where it is.

Hv.

Yoiu posted

and then

  44. ExecIf($["${DIRECTION}" = "INBOUND"]?Set(D_OPTIONS=${STRREPLACE(D_OPTIONS,T)}I)) [pbx_config]

            45. Dial(${DSTRING},${ARG1},${D_OPTIONS})     [pbx_config]

That is why, you did it wrong.

and further I am not aware that I is a a usable argument to replace T in the dial command

1 Like

Ahh cool now we got that sorted out.

Now that one is posted above the other, do you think I should report it as an error.? :wink:

I just thought that whoever or whatever created line 44 of [macro-dial-one] may have made a typeO.
Much like you telling me I had I guess.

Hv.

You could post it to yourself as an error.

True,
But then I would want to forward it to the department that wrote that line.

We seem to be in loop while 1 mode.

Hv.

I will now exit that loop.

Don’t blame ya,
But it feels like I am saying the Sky is Blue and your telling me to stop painting it Red.

It’s Blue. :sunny: -)

Guess I shall drop a report just in case the type-o has lingered thru the versions.

hv.

Perhaps it is an error, sorry , I don’t yet use that patch. and I IS actually valid in Asterisk 11+ dial. If this box is less then that is probably the problem. And the patch does seem correct, oops bad me :frowning:

Na I would not stress, I find it fun.
And best that someone ensure the person thinking of reporting is fairly sure.!!

I dropped a report on the other place.
Lets see what they have to say.

Hv.

When it says “not registered” thats because the function doesn’t exist, the code is actually correct. Upgrade your asterisk 1.8 to something new that’s actually supported. Like asterisk 11

1 Like