1 /* Copyright 2010, 2011 NORDUnet A/S. All rights reserved.
2 See the file COPYING for licensing information. */
4 #if defined HAVE_CONFIG_H
8 #include <freeradius/libradius.h>
9 #include <radsec/radsec.h>
10 #include <radsec/radsec-impl.h>
13 rs_attr_create(struct rs_connection *conn, struct rs_attr **attr, const char *type, const char *val)
19 a = (struct rs_attr *) malloc (sizeof(struct rs_attr));
21 return rs_err_conn_push_fl (conn, RSE_NOMEM, __FILE__, __LINE__, NULL);
22 memset (a, 0, sizeof(struct rs_attr));
24 vp = pairmake (type, val, T_OP_EQ);
28 return rs_err_conn_push_fl (conn, RSE_FR, __FILE__, __LINE__,
29 "pairmake: %s", fr_strerror ());
38 rs_attr_destroy (struct rs_attr *attr)