unlang test issue

Alan DeKok aland at deployingradius.com
Wed Sep 10 15:00:27 CEST 2014


BALSIANOK, Peter wrote:
>     update reply {
>        Framed-IP-Address := 0

  Updating the REPLY.

>     if(<ipaddr>0.0.0.0 == &Framed-IP-Address) {

  Looking at the REQUEST.

  And that's backwards.  Just do:

	if (&reply:Framed-IP-Address == 0.0.0.0)

  This isn't the C language.  You can't assign anything in an "if"
condition.  So there's no reason to put constants on the left side of a
condition.

  Alan DeKok.


More information about the Freeradius-Users mailing list