summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorhenning <henning@openbsd.org>2004-01-05 19:06:42 +0000
committerhenning <henning@openbsd.org>2004-01-05 19:06:42 +0000
commitbdfb70b00acf96320c2122f47f4e12a6c238b61e (patch)
tree3db98f668fdbc8ca5024f96599a1a04f1e00bd07
parentfix off by ones with strlcpy() (diff)
downloadwireguard-openbsd-bdfb70b00acf96320c2122f47f4e12a6c238b61e.tar.xz
wireguard-openbsd-bdfb70b00acf96320c2122f47f4e12a6c238b61e.zip
remove support for reading configuration from stdin.
that really does not make sense with a daemon and probably breaks horribly on config reload
-rw-r--r--usr.sbin/bgpd/parse.y19
1 files changed, 7 insertions, 12 deletions
diff --git a/usr.sbin/bgpd/parse.y b/usr.sbin/bgpd/parse.y
index 6debcc38b8d..d0e5c6d4557 100644
--- a/usr.sbin/bgpd/parse.y
+++ b/usr.sbin/bgpd/parse.y
@@ -1,4 +1,4 @@
-/* $OpenBSD: parse.y,v 1.27 2004/01/05 19:04:11 henning Exp $ */
+/* $OpenBSD: parse.y,v 1.28 2004/01/05 19:06:42 henning Exp $ */
/*
* Copyright (c) 2002, 2003 Henning Brauer <henning@openbsd.org>
@@ -570,18 +570,13 @@ parse_config(char *filename, struct bgpd_config *xconf,
conf->listen_addr.sin_addr.s_addr = INADDR_ANY;
conf->listen_addr.sin_port = htons(BGP_PORT);
- if (strcmp(filename, "-") == 0) {
- fin = stdin;
- infile = "stdin";
- } else {
- if ((fin = fopen(filename, "r")) == NULL) {
- warn("%s", filename);
- free(conf);
- free(mrtconf);
- return (-1);
- }
- infile = filename;
+ if ((fin = fopen(filename, "r")) == NULL) {
+ warn("%s", filename);
+ free(conf);
+ free(mrtconf);
+ return (-1);
}
+ infile = filename;
yyparse();