On Monday 14 June 2010, Steven C. Blair wrote:
I’m migrating from an older version of SER to
sip-router. A syntax check
of my config file produces a few errors. The most confusing is :
0(27980) WARNING: <core> [cfg.y:3364]: warning in config file
/home/blairs/ser-penn.cfg, line 1270, column 22-23: non constant rvalue in
ip comparison
Line 1270 is the following if statement:
if (to_ip==$g.gw_ip && !isflagset(FLAG_PSTN_ALLOWED)
&& !isflagset(FLAG_TOTAG)
&& method != "ACK" && method !=
"CANCEL")
I do not see anything mentioned in config_migration.txt which explains this
warning. Does anyone have any thoughts on how to correct this error?
Hi Steven,
for the term "rvalue", its somewhat described e.g. here:
http://en.wikipedia.org/wiki/Value_(computer_science)
The error message probably means that the $g.gw_ip can not compared against
the to_ip variable.
Do you get also this first error:
0(8530) : <core> [cfg.y:3396]: parse error in config file sip-
router/test/unit/foo.cfg, line 5, column 6-10: to_ip allowed only in
onsend_routes
0(8530) WARNING: <core> [cfg.y:3376]: warning in config file sip-
router/test/unit/foo.cfg, line 5, column 21: non constant rvalue in ip
comparison
Then i think we know the problem from the first log message. :) If you just
want to compare against the To domain header, you could use the appropriate
pseudo-variable or the proper select.
Cheers,
Henning