Hi AVPs are tied to transactions, after the processing the avp is cleaned, you can't test for duplicate messages in this way. I suggest you check the core functions cache_store() and cache_fetch(). You can save in memory the call-id of each message ($ci) and if it is duplicated, drop.
Flavio E. Goncalves 2013/1/1 Dragomir Haralambiev <[email protected]> > Hello, > > My opensips receive a lot of a same messages. > I try to fix this with follow part of script. > Why not working? > > if (is_method("MESSAGE")) { > > if ( $avp(receive_message) == $ci ) { > xlog("L_ERR", "I receive already this MESSAGE"); > exit; > } > $avp(receive_message) = $ci; > ............................. > } > > Regards, > PlayMen > > _______________________________________________ > Users mailing list > [email protected] > http://lists.opensips.org/cgi-bin/mailman/listinfo/users >
_______________________________________________ Users mailing list [email protected] http://lists.opensips.org/cgi-bin/mailman/listinfo/users
