Deleted Added
full compact
key.c (221129) key.c (221692)
1/* $FreeBSD: head/sys/netipsec/key.c 221129 2011-04-27 19:28:42Z bz $ */
1/* $FreeBSD: head/sys/netipsec/key.c 221692 2011-05-09 13:16:21Z vanhu $ */
2/* $KAME: key.c,v 1.191 2001/06/27 10:46:49 sakane Exp $ */
3
4/*-
5 * Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
6 * All rights reserved.
7 *
8 * Redistribution and use in source and binary forms, with or without
9 * modification, are permitted provided that the following conditions

--- 2268 unchanged lines hidden (view full) ---

2278
2279 /* Is there SP in SPD ? */
2280 if ((sp = key_getspbyid(id)) == NULL) {
2281 ipseclog((LOG_DEBUG, "%s: no SP found id:%u.\n", __func__, id));
2282 return key_senderror(so, m, ENOENT);
2283 }
2284
2285 n = key_setdumpsp(sp, SADB_X_SPDGET, 0, mhp->msg->sadb_msg_pid);
2/* $KAME: key.c,v 1.191 2001/06/27 10:46:49 sakane Exp $ */
3
4/*-
5 * Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
6 * All rights reserved.
7 *
8 * Redistribution and use in source and binary forms, with or without
9 * modification, are permitted provided that the following conditions

--- 2268 unchanged lines hidden (view full) ---

2278
2279 /* Is there SP in SPD ? */
2280 if ((sp = key_getspbyid(id)) == NULL) {
2281 ipseclog((LOG_DEBUG, "%s: no SP found id:%u.\n", __func__, id));
2282 return key_senderror(so, m, ENOENT);
2283 }
2284
2285 n = key_setdumpsp(sp, SADB_X_SPDGET, 0, mhp->msg->sadb_msg_pid);
2286 KEY_FREESP(&sp);
2286 if (n != NULL) {
2287 m_freem(m);
2288 return key_sendup_mbuf(so, n, KEY_SENDUP_ONE);
2289 } else
2290 return key_senderror(so, m, ENOBUFS);
2291}
2292
2293/*

--- 5787 unchanged lines hidden ---
2287 if (n != NULL) {
2288 m_freem(m);
2289 return key_sendup_mbuf(so, n, KEY_SENDUP_ONE);
2290 } else
2291 return key_senderror(so, m, ENOBUFS);
2292}
2293
2294/*

--- 5787 unchanged lines hidden ---