Lines Matching defs:new
1223 struct inpcbpolicy *new;
1229 new = ipsec_newpcbpolicy();
1230 if (new == NULL) {
1234 bzero(new, sizeof(*new));
1241 new->priv = 1;
1243 new->priv = 0;
1245 if ((new->sp_in = key_newsp()) == NULL) {
1246 ipsec_delpcbpolicy(new);
1249 new->sp_in->state = IPSEC_SPSTATE_ALIVE;
1250 new->sp_in->policy = IPSEC_POLICY_ENTRUST;
1252 if ((new->sp_out = key_newsp()) == NULL) {
1253 key_freesp(new->sp_in, KEY_SADB_UNLOCKED);
1254 ipsec_delpcbpolicy(new);
1257 new->sp_out->state = IPSEC_SPSTATE_ALIVE;
1258 new->sp_out->policy = IPSEC_POLICY_ENTRUST;
1260 *pcb_sp = new;
1265 /* copy old ipsec policy into new */
1267 ipsec_copy_policy(old, new)
1268 struct inpcbpolicy *old, *new;
1277 key_freesp(new->sp_in, KEY_SADB_UNLOCKED);
1278 new->sp_in = sp;
1284 key_freesp(new->sp_out, KEY_SADB_UNLOCKED);
1285 new->sp_out = sp;
1289 new->priv = old->priv;
1388 /* allocation new SP entry */
1394 /* clear old SP and set new SP */
1398 printf("ipsec_set_policy: new policy\n");
2193 * grow the mbuf to accomodate the new IPv4 header.
2219 /* construct new IPv4 header. see RFC 2401 5.1.2.1 */
2291 * grow the mbuf to accomodate the new IPv6 header.
2322 /* construct new IPv6 header. see RFC 2401 5.1.2.2 */
2371 * grow the mbuf to accomodate the new IPv4 header.
2393 /* construct new IPv4 header. see RFC 2401 5.1.2.1 */
2553 /* new larger sequence number */
3806 * allocate a new cluster and copy the data to the new cluster.