summaryrefslogtreecommitdiff
path: root/bin/systrace/intercept-translate.c
diff options
context:
space:
mode:
Diffstat (limited to 'bin/systrace/intercept-translate.c')
-rw-r--r--bin/systrace/intercept-translate.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/bin/systrace/intercept-translate.c b/bin/systrace/intercept-translate.c
index 8409ddd8f3b..43b01f596f4 100644
--- a/bin/systrace/intercept-translate.c
+++ b/bin/systrace/intercept-translate.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: intercept-translate.c,v 1.5 2002/07/13 08:53:02 provos Exp $ */
+/* $OpenBSD: intercept-translate.c,v 1.6 2002/07/14 22:34:55 provos Exp $ */
/*
* Copyright 2002 Niels Provos <provos@citi.umich.edu>
* All rights reserved.
@@ -145,6 +145,9 @@ ic_get_string(struct intercept_translate *trans, int fd, pid_t pid, void *addr)
char *name;
int len;
+ if (addr == NULL)
+ return (-1);
+
name = intercept_get_string(fd, pid, addr);
if (name == NULL)
return (-1);