diff options
author | Todd C. Miller <millert@cvs.openbsd.org> | 2002-05-16 17:54:35 +0000 |
---|---|---|
committer | Todd C. Miller <millert@cvs.openbsd.org> | 2002-05-16 17:54:35 +0000 |
commit | d83e86c9d0a95f30a0001af441e0b0ab56e61ea5 (patch) | |
tree | 8ae4b85d82594a6aebdac8629c9f06ebe2875f5a /usr.bin/skeyinit/skeyinit.c | |
parent | 05c9c456872ecdf55dfa2deb4e9e411372a9ee5e (diff) |
Add missing chown(2) call.
Diffstat (limited to 'usr.bin/skeyinit/skeyinit.c')
-rw-r--r-- | usr.bin/skeyinit/skeyinit.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/usr.bin/skeyinit/skeyinit.c b/usr.bin/skeyinit/skeyinit.c index c340f0ec003..fd86ba6523a 100644 --- a/usr.bin/skeyinit/skeyinit.c +++ b/usr.bin/skeyinit/skeyinit.c @@ -1,4 +1,4 @@ -/* $OpenBSD: skeyinit.c,v 1.32 2002/05/16 03:50:42 millert Exp $ */ +/* $OpenBSD: skeyinit.c,v 1.33 2002/05/16 17:54:34 millert Exp $ */ /* OpenBSD S/Key (skeyinit.c) * @@ -429,6 +429,8 @@ enable_db(op) /* enable */ if (mkdir(_PATH_SKEYDIR, 01730) != 0 && errno != EEXIST) err(1, "can't mkdir %s", _PATH_SKEYDIR); + if (chown(_PATH_SKEYDIR, geteuid(), getegid()) != 0) + err(1, "can't chown %s", _PATH_SKEYDIR); if (chmod(_PATH_SKEYDIR, 01730) != 0) err(1, "can't chmod %s", _PATH_SKEYDIR); } else { |