Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/netbsd-1-5]: src/sys/netkey Pull up rev. 1.24:
details: https://anonhg.NetBSD.org/src/rev/1c24d68e8b8c
branches: netbsd-1-5
changeset: 488249:1c24d68e8b8c
user: thorpej <thorpej%NetBSD.org@localhost>
date: Sat Jun 24 18:05:09 2000 +0000
description:
Pull up rev. 1.24:
Clean up some NULL vs. 0 confusion, and fix a bogus comparison.
diffstat:
sys/netkey/key.c | 10 +++++-----
1 files changed, 5 insertions(+), 5 deletions(-)
diffs (45 lines):
diff -r 2eb0c0597ebc -r 1c24d68e8b8c sys/netkey/key.c
--- a/sys/netkey/key.c Sat Jun 24 11:15:46 2000 +0000
+++ b/sys/netkey/key.c Sat Jun 24 18:05:09 2000 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: key.c,v 1.23 2000/06/15 13:44:22 itojun Exp $ */
+/* $NetBSD: key.c,v 1.23.2.1 2000/06/24 18:05:09 thorpej Exp $ */
/* $KAME: key.c,v 1.132 2000/06/15 13:41:49 itojun Exp $ */
/*
@@ -1554,7 +1554,7 @@
printf("key_spdadd: Invalid SP direction.\n");
#endif
mhp->msg->sadb_msg_errno = EINVAL;
- return NULL;
+ return 0;
}
/* check policy */
@@ -1872,7 +1872,7 @@
printf("key_spddelete2: invalid message is passed.\n");
#endif
key_senderror(so, m, EINVAL);
- return NULL;
+ return 0;
}
id = ((struct sadb_x_policy *)mhp->ext[SADB_X_EXT_POLICY])->sadb_x_policy_id;
@@ -4860,7 +4860,7 @@
#endif
return key_senderror(so, m, EINVAL);
}
- if (mhp->extlen[SADB_EXT_SA] == NULL < sizeof(struct sadb_sa) ||
+ if (mhp->extlen[SADB_EXT_SA] < sizeof(struct sadb_sa) ||
mhp->extlen[SADB_EXT_ADDRESS_SRC] < sizeof(struct sadb_address) ||
mhp->extlen[SADB_EXT_ADDRESS_DST] < sizeof(struct sadb_address)) {
/* XXX need more */
@@ -4916,7 +4916,7 @@
}
/* check SA values to be mature. */
- if ((error = key_mature(newsav)) != NULL) {
+ if ((error = key_mature(newsav)) != 0) {
key_freesav(newsav);
return key_senderror(so, m, error);
}
Home |
Main Index |
Thread Index |
Old Index