diff options
author | Jun-ichiro itojun Hagino <itojun@cvs.openbsd.org> | 2002-10-09 03:52:11 +0000 |
---|---|---|
committer | Jun-ichiro itojun Hagino <itojun@cvs.openbsd.org> | 2002-10-09 03:52:11 +0000 |
commit | 287d5c0ae8d639fe6a50dc5910f9ed406a1fe6ce (patch) | |
tree | 1a4670ffbe7a25a23ce76091971541b1e5e9d052 /bin/systrace/util.c | |
parent | 4cfdfd9c10ffaed2194d3f0b1aa40e39045225f7 (diff) |
predicates are part of the grammar now; in non-root case, predicates are
evaluated only once; in root case, predicates and variable expansion are
dynamic.
from provos
Diffstat (limited to 'bin/systrace/util.c')
-rw-r--r-- | bin/systrace/util.c | 18 |
1 files changed, 1 insertions, 17 deletions
diff --git a/bin/systrace/util.c b/bin/systrace/util.c index ad1d4230f2b..b6bd8b17cd2 100644 --- a/bin/systrace/util.c +++ b/bin/systrace/util.c @@ -1,4 +1,4 @@ -/* $OpenBSD: util.c,v 1.8 2002/07/19 14:38:58 itojun Exp $ */ +/* $OpenBSD: util.c,v 1.9 2002/10/09 03:52:10 itojun Exp $ */ /* * Copyright 2002 Niels Provos <provos@citi.umich.edu> * All rights reserved. @@ -33,7 +33,6 @@ #include <string.h> #include <ctype.h> #include <stdio.h> -#include <pwd.h> #include "util.h" @@ -71,21 +70,6 @@ strrpl(char *str, size_t size, char *match, char *value) return (p); } -char * -uid_to_name(uid_t uid) -{ - static char buf[128]; - struct passwd *pw; - - if ((pw = getpwuid(uid)) == NULL) - snprintf(buf, sizeof(buf), "uid %u", uid); - else - snprintf(buf, sizeof(buf), "%s", pw->pw_name); - - return (buf); -} - - /* simplify_path is from pdksh and apparently in the public domain */ /* ISABSPATH() means path is fully and completely specified, |