Summary:ASTERISK-07348: Spaces in setvar= command not accepted
Reporter:Douglas Garstang (dgarstang)Labels:
Date Opened:2006-07-17 13:57:51Date Closed:2006-07-17 16:41:28
Versions:Frequency of
Description:Setting the following in sip.conf works ok:

However, the following does not set the variable val=var
setvar = val = var

Given that all other settings in sip.conf seem to be ok with whitespace, I can't see why setvar should be any different.
Comments:By: Anthony LaMantia (alamantia) 2006-07-17 14:25:07


can you give me an example block from the sip.conf you are working with, and a backtrace if the sip.conf you are using is causing asterisk to sig11 at all.


By: Jason Parker (jparker) 2006-07-17 16:09:53

I doubt it will make much of a difference, but please try this (as with every other bug report..) with the latest svn revision in the appropriate branch.

I believe this will affect some other channel drivers too.

By: Jason Parker (jparker) 2006-07-17 16:14:59

Thinking about this a little more...I move to close this bug.

"setvar = var=val" will work, and you can't possibly expect "nat = y e s" to work, so...

It is my opinion that spaces SHOULD be allowed in setvar, so you can do something like "setvar=foo bar=baz", and then reference it later with ${foo bar}.

What is happening in the above is that you are setting the variable "var ", ie; ${var } to " val".

By: Douglas Garstang (dgarstang) 2006-07-17 16:39:19

I guess close it then, as I don't have any means to test with latest SVN code anyways. I'll just have to deal with this as an annoyance.

By: Jason Parker (jparker) 2006-07-17 16:41:28

If somebody has a better reason why this should be changed, they can ask a bug marshal to reopen this report.