[OpenSER-Devel] SF.net SVN: openser: [2420] trunk

Daniel-Constantin Mierla daniel at voice-system.ro
Mon Jul 9 13:12:03 CEST 2007


Hello,

On 07/09/07 13:29, Juha Heinanen wrote:
> Daniel-Constantin Mierla writes:
>
>  > operating with null cannot be consistent unless we change all PV 
>  > concept. $avp() = null deletes the avp, $var() = null, resets to 0, $du 
>  > = null (and other pv) set to null some internal structures. 
>
> as a concrete example, how can i figure out if request uri userpart
> exists?  
>
> i tried to test if len of $rU is 0, but got 1:
>
> 	$rU = null;
> 	xlog("L_INFO", "Request URI <$ru>\n");
> 	if ($(rU{s.len}) == 0) {
> 		xlog("L_INFO", "Length is 0\n");
> 	}
> 	if ($(rU{s.len}) == 1) {
> 		xlog("L_INFO", "Length is 1\n");
> 	}
>
> prints to syslog
>
> Jul  9 13:27:54 localhost /usr/sbin/openser[16006]: Request URI <sip:test.fi>
> Jul  9 13:27:54 localhost /usr/sbin/openser[16006]: Length is 1
>
> which is still the bug that i reported a while back.
>   
I applied now the same fix as in devel to 1.2 -- if PV is null, then no 
transformation can be applied.

The issue comes because no coherent implementation was found so far for 
PV and NULL, perhaps we should start a public discussion to see what is 
the best solution out there. If you have some ideas, please bring then up.

Cheers,
Daniel

> -- juha
>
>   



More information about the Devel mailing list