summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorotto <otto@openbsd.org>2007-09-23 20:13:28 +0000
committerotto <otto@openbsd.org>2007-09-23 20:13:28 +0000
commitfbe536297cf613a0449da7fa2d7a72e7ce089e89 (patch)
treeba4ee9de0a4365fd0993b99ddd8e43fd5a336253
parentPull form ragge's repo: (diff)
downloadwireguard-openbsd-fbe536297cf613a0449da7fa2d7a72e7ce089e89.tar.xz
wireguard-openbsd-fbe536297cf613a0449da7fa2d7a72e7ce089e89.zip
Avoid potential segfault when debugging
-rw-r--r--usr.bin/pcc/cc/ccom/pftn.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/usr.bin/pcc/cc/ccom/pftn.c b/usr.bin/pcc/cc/ccom/pftn.c
index 7d4c3a8169b..11de483c199 100644
--- a/usr.bin/pcc/cc/ccom/pftn.c
+++ b/usr.bin/pcc/cc/ccom/pftn.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pftn.c,v 1.3 2007/09/16 18:52:52 otto Exp $ */
+/* $OpenBSD: pftn.c,v 1.4 2007/09/23 20:13:28 otto Exp $ */
/*
* Copyright (c) 2003 Anders Magnusson (ragge@ludd.luth.se).
* All rights reserved.
@@ -2046,7 +2046,8 @@ doacall(NODE *f, NODE *a)
if (ddebug) {
printf("doacall.\n");
fwalk(f, eprint, 0);
- fwalk(a, eprint, 0);
+ if (a)
+ fwalk(a, eprint, 0);
}
#endif