diff options
Diffstat (limited to 'servconf.c')
-rw-r--r-- | servconf.c | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/servconf.c b/servconf.c index d4c01f7ff..4e3140fe3 100644 --- a/servconf.c +++ b/servconf.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: servconf.c,v 1.173 2007/12/27 14:22:08 dtucker Exp $ */ | 1 | /* $OpenBSD: servconf.c,v 1.174 2007/12/31 10:41:31 dtucker Exp $ */ |
2 | /* | 2 | /* |
3 | * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland | 3 | * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland |
4 | * All rights reserved | 4 | * All rights reserved |
@@ -621,6 +621,8 @@ process_server_config_line(ServerOptions *options, char *line, | |||
621 | { | 621 | { |
622 | char *cp, **charptr, *arg, *p; | 622 | char *cp, **charptr, *arg, *p; |
623 | int cmdline = 0, *intptr, value, n; | 623 | int cmdline = 0, *intptr, value, n; |
624 | SyslogFacility *log_facility_ptr; | ||
625 | LogLevel *log_level_ptr; | ||
624 | ServerOpCodes opcode; | 626 | ServerOpCodes opcode; |
625 | u_short port; | 627 | u_short port; |
626 | u_int i, flags = 0; | 628 | u_int i, flags = 0; |
@@ -976,25 +978,25 @@ parse_flag: | |||
976 | goto parse_flag; | 978 | goto parse_flag; |
977 | 979 | ||
978 | case sLogFacility: | 980 | case sLogFacility: |
979 | intptr = (int *) &options->log_facility; | 981 | log_facility_ptr = &options->log_facility; |
980 | arg = strdelim(&cp); | 982 | arg = strdelim(&cp); |
981 | value = log_facility_number(arg); | 983 | value = log_facility_number(arg); |
982 | if (value == SYSLOG_FACILITY_NOT_SET) | 984 | if (value == SYSLOG_FACILITY_NOT_SET) |
983 | fatal("%.200s line %d: unsupported log facility '%s'", | 985 | fatal("%.200s line %d: unsupported log facility '%s'", |
984 | filename, linenum, arg ? arg : "<NONE>"); | 986 | filename, linenum, arg ? arg : "<NONE>"); |
985 | if (*intptr == -1) | 987 | if (*log_facility_ptr == -1) |
986 | *intptr = (SyslogFacility) value; | 988 | *log_facility_ptr = (SyslogFacility) value; |
987 | break; | 989 | break; |
988 | 990 | ||
989 | case sLogLevel: | 991 | case sLogLevel: |
990 | intptr = (int *) &options->log_level; | 992 | log_level_ptr = &options->log_level; |
991 | arg = strdelim(&cp); | 993 | arg = strdelim(&cp); |
992 | value = log_level_number(arg); | 994 | value = log_level_number(arg); |
993 | if (value == SYSLOG_LEVEL_NOT_SET) | 995 | if (value == SYSLOG_LEVEL_NOT_SET) |
994 | fatal("%.200s line %d: unsupported log level '%s'", | 996 | fatal("%.200s line %d: unsupported log level '%s'", |
995 | filename, linenum, arg ? arg : "<NONE>"); | 997 | filename, linenum, arg ? arg : "<NONE>"); |
996 | if (*intptr == -1) | 998 | if (*log_level_ptr == -1) |
997 | *intptr = (LogLevel) value; | 999 | *log_level_ptr = (LogLevel) value; |
998 | break; | 1000 | break; |
999 | 1001 | ||
1000 | case sAllowTcpForwarding: | 1002 | case sAllowTcpForwarding: |