summaryrefslogtreecommitdiff
path: root/sbin
diff options
context:
space:
mode:
authorAaron Campbell <aaron@cvs.openbsd.org>2002-08-02 17:09:30 +0000
committerAaron Campbell <aaron@cvs.openbsd.org>2002-08-02 17:09:30 +0000
commit977fa39ace69d23d01d5a62c1c3fda0b55729478 (patch)
tree679815a52e3602fba90b4a6b819bd7a30132f6b3 /sbin
parentbe4543235bb8b2ea010ac14e17ed4c6496d3d727 (diff)
Check inet_aton() failure with == 0, not == -1; millert@ ok.
Diffstat (limited to 'sbin')
-rw-r--r--sbin/isakmpd/apps/certpatch/certpatch.c4
-rw-r--r--sbin/isakmpd/regress/x509/x509test.c4
2 files changed, 4 insertions, 4 deletions
diff --git a/sbin/isakmpd/apps/certpatch/certpatch.c b/sbin/isakmpd/apps/certpatch/certpatch.c
index 98b4da69408..cc6cd84fc6f 100644
--- a/sbin/isakmpd/apps/certpatch/certpatch.c
+++ b/sbin/isakmpd/apps/certpatch/certpatch.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: certpatch.c,v 1.18 2002/06/09 08:13:07 todd Exp $ */
+/* $OpenBSD: certpatch.c,v 1.19 2002/08/02 17:09:29 aaron Exp $ */
/* $EOM: certpatch.c,v 1.11 2000/12/21 14:50:09 ho Exp $ */
/*
@@ -186,7 +186,7 @@ main (int argc, char **argv)
if (!strcasecmp (IDTYPE_IP, type))
{
- if (inet_aton (id, &saddr) == -1)
+ if (inet_aton (id, &saddr) == 0)
{
printf ("inet_aton () failed\n");
return (1);
diff --git a/sbin/isakmpd/regress/x509/x509test.c b/sbin/isakmpd/regress/x509/x509test.c
index 08b3db0c9e4..de4f14b5722 100644
--- a/sbin/isakmpd/regress/x509/x509test.c
+++ b/sbin/isakmpd/regress/x509/x509test.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: x509test.c,v 1.20 2002/06/10 18:08:59 ho Exp $ */
+/* $OpenBSD: x509test.c,v 1.21 2002/08/02 17:09:29 aaron Exp $ */
/* $EOM: x509test.c,v 1.9 2000/12/21 15:24:25 ho Exp $ */
/*
@@ -268,7 +268,7 @@ main (int argc, char *argv[])
if (argc == 4)
{
printf ("Verifying extension: ");
- if (inet_aton (argv[3], &saddr) == -1)
+ if (inet_aton (argv[3], &saddr) == 0)
{
printf ("inet_aton () failed\n");
exit (1);