[Serdev] Finding AVPs

Pupeno pupeno at pupeno.com
Thu Apr 13 11:19:22 UTC 2006


Hello,
I need to check some AVPs in a module I am developing, I think I have to start 
with this function:

avp_t *search_first_avp( avp_flags_t flags, avp_name_t name, avp_value_t *val, 
struct search_state* state);

now, this raises various questions. What is val passed for ? can it find a 
precise name/value pair (it doesn't seem to do that) or there returns the 
value of the AVP found (it doesn't seem to do that either) ?

It returns an avp_t, which is:

typedef struct usr_avp {
	avp_id_t id;
	     /* Flags that are kept for the AVP lifetime */
	avp_flags_t flags;
	struct usr_avp *next;
	void *data;
} avp_t;

What is id ? what should I expect to have on next ? other AVPs with the same 
name ? Is that even possible ? And what about data ? would there be the 
value ?

All that I need to do is check for a name/value pair which I have.

Thanks.
-- 
Pupeno <pupeno at pupeno.com> (http://pupeno.com)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
Url : http://lists.iptel.org/pipermail/serdev/attachments/20060413/57bd9616/attachment.pgp


More information about the Serdev mailing list