- dtucker@cvs.openbsd.org 2004/05/27 00:50:13
[readconf.c] Kill dead code after fatal(); ok djm@
This commit is contained in:
parent
3e4dffb140
commit
3379385060
|
@ -6,6 +6,9 @@
|
||||||
- markus@cvs.openbsd.org 2004/05/26 23:02:39
|
- markus@cvs.openbsd.org 2004/05/26 23:02:39
|
||||||
[channels.c]
|
[channels.c]
|
||||||
missing freeaddrinfo; Andrey Matveev
|
missing freeaddrinfo; Andrey Matveev
|
||||||
|
- dtucker@cvs.openbsd.org 2004/05/27 00:50:13
|
||||||
|
[readconf.c]
|
||||||
|
Kill dead code after fatal(); ok djm@
|
||||||
|
|
||||||
20040603
|
20040603
|
||||||
- (dtucker) [auth-pam.c] Don't use pam_* namespace for sshd's PAM functions.
|
- (dtucker) [auth-pam.c] Don't use pam_* namespace for sshd's PAM functions.
|
||||||
|
@ -1190,4 +1193,4 @@
|
||||||
- (djm) Trim deprecated options from INSTALL. Mention UsePAM
|
- (djm) Trim deprecated options from INSTALL. Mention UsePAM
|
||||||
- (djm) Fix quote handling in sftp; Patch from admorten AT umich.edu
|
- (djm) Fix quote handling in sftp; Patch from admorten AT umich.edu
|
||||||
|
|
||||||
$Id: ChangeLog,v 1.3376 2004/06/15 00:27:15 djm Exp $
|
$Id: ChangeLog,v 1.3377 2004/06/15 00:27:55 djm Exp $
|
||||||
|
|
11
readconf.c
11
readconf.c
|
@ -12,7 +12,7 @@
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "includes.h"
|
#include "includes.h"
|
||||||
RCSID("$OpenBSD: readconf.c,v 1.130 2004/04/27 09:46:36 djm Exp $");
|
RCSID("$OpenBSD: readconf.c,v 1.131 2004/05/27 00:50:13 dtucker Exp $");
|
||||||
|
|
||||||
#include "ssh.h"
|
#include "ssh.h"
|
||||||
#include "xmalloc.h"
|
#include "xmalloc.h"
|
||||||
|
@ -809,16 +809,11 @@ read_config_file(const char *filename, const char *host, Options *options,
|
||||||
if (checkperm) {
|
if (checkperm) {
|
||||||
struct stat sb;
|
struct stat sb;
|
||||||
|
|
||||||
if (fstat(fileno(f), &sb) == -1) {
|
if (fstat(fileno(f), &sb) == -1)
|
||||||
fatal("fstat %s: %s", filename, strerror(errno));
|
fatal("fstat %s: %s", filename, strerror(errno));
|
||||||
fclose(f);
|
|
||||||
return (0);
|
|
||||||
}
|
|
||||||
if (((sb.st_uid != 0 && sb.st_uid != getuid()) ||
|
if (((sb.st_uid != 0 && sb.st_uid != getuid()) ||
|
||||||
(sb.st_mode & 022) != 0)) {
|
(sb.st_mode & 022) != 0))
|
||||||
fatal("Bad owner or permissions on %s", filename);
|
fatal("Bad owner or permissions on %s", filename);
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
debug("Reading configuration data %.200s", filename);
|
debug("Reading configuration data %.200s", filename);
|
||||||
|
|
Loading…
Reference in New Issue