summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorderaadt <deraadt@openbsd.org>2000-12-13 06:36:05 +0000
committerderaadt <deraadt@openbsd.org>2000-12-13 06:36:05 +0000
commitd7531e869c525d3d84166f48d9d9fa65b393834e (patch)
treeb17250cd81c243598b61387438e5c9ae0e409745
parentOn vax build libgcc without -fPIC for now. (diff)
downloadwireguard-openbsd-d7531e869c525d3d84166f48d9d9fa65b393834e.tar.xz
wireguard-openbsd-d7531e869c525d3d84166f48d9d9fa65b393834e.zip
KNF
-rw-r--r--usr.bin/ssh/pty.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/usr.bin/ssh/pty.c b/usr.bin/ssh/pty.c
index 442ed11a125..b7430c3445b 100644
--- a/usr.bin/ssh/pty.c
+++ b/usr.bin/ssh/pty.c
@@ -12,7 +12,7 @@
*/
#include "includes.h"
-RCSID("$OpenBSD: pty.c,v 1.17 2000/12/12 22:50:21 ho Exp $");
+RCSID("$OpenBSD: pty.c,v 1.18 2000/12/13 06:36:05 deraadt Exp $");
#include <util.h>
#include "pty.h"
@@ -270,13 +270,13 @@ pty_setowner(struct passwd *pw, const char *ttyname)
* Change owner and mode of the tty as required.
* Warn but continue if filesystem is read-only and the uids match.
*/
- if (stat (ttyname, &st))
+ if (stat(ttyname, &st))
fatal("stat(%.100s) failed: %.100s", ttyname,
strerror(errno));
if (st.st_uid != pw->pw_uid || st.st_gid != gid) {
- if (chown (ttyname, pw->pw_uid, gid) < 0) {
- if ((errno == EROFS) && (st.st_uid == pw->pw_uid))
+ if (chown(ttyname, pw->pw_uid, gid) < 0) {
+ if (errno == EROFS && st.st_uid == pw->pw_uid)
error("chown(%.100s, %d, %d) failed: %.100s",
ttyname, pw->pw_uid, gid,
strerror(errno));
@@ -288,9 +288,9 @@ pty_setowner(struct passwd *pw, const char *ttyname)
}
if ((st.st_mode & (S_IRWXU|S_IRWXG|S_IRWXO)) != mode) {
- if (chmod (ttyname, mode) < 0) {
- if ((errno == EROFS) &&
- ((st.st_mode & (S_IRGRP | S_IROTH)) == 0))
+ if (chmod(ttyname, mode) < 0) {
+ if (errno == EROFS &&
+ (st.st_mode & (S_IRGRP | S_IROTH)) == 0)
error("chmod(%.100s, 0%o) failed: %.100s",
ttyname, mode, strerror(errno));
else