diff options
author | paul <paul> | 2005-04-05 00:45:23 +0000 |
---|---|---|
committer | paul <paul> | 2005-04-05 00:45:23 +0000 |
commit | 3d1dc85765816a92f06e0b11f52411dac0f8abae (patch) | |
tree | d20333a4ddbc271e11998834a4fdbc0e3acd719d /lib | |
parent | 5b0875287206a0ac1ebe1dca1f6235b8f3df1764 (diff) |
2004-04-05 Paul Jakma <paul@dishone.st>
* lib/vty.c: Improve logging of failures to open vty socket(s).
See bugid #163.
* zebra/zserv.c: print more helpful errors when we fail to successfully
bind and listen on zserv socket. Closes bugzilla #163.
Diffstat (limited to 'lib')
-rw-r--r-- | lib/ChangeLog | 5 | ||||
-rw-r--r-- | lib/vty.c | 10 |
2 files changed, 13 insertions, 2 deletions
diff --git a/lib/ChangeLog b/lib/ChangeLog index 6701a90d..57bb3d1c 100644 --- a/lib/ChangeLog +++ b/lib/ChangeLog @@ -1,3 +1,8 @@ +2004-04-05 Paul Jakma <paul@dishone.st> + + * vty.c: Improve logging of failures to open vty socket(s). + See bugid #163. + 2005-04-02 Andrew J. Schorr <ajschorr@alumni.princeton.edu> * if.h: Fix comments to reflect that if_lookup_by_name and @@ -2297,13 +2297,16 @@ vty_read_config (char *config_file, if (confp == NULL) { + fprintf (stderr, "%s: failed to open configuration file %s: %s\n", + __func__, fullpath, safe_strerror (errno)); + confp = vty_use_backup_config (fullpath); if (confp) fprintf (stderr, "WARNING: using backup configuration file!\n"); else { fprintf (stderr, "can't open configuration file [%s]\n", - config_file); + config_file); exit(1); } } @@ -2339,6 +2342,9 @@ vty_read_config (char *config_file, confp = fopen (config_default_dir, "r"); if (confp == NULL) { + fprintf (stderr, "%s: failed to open configuration file %s: %s\n", + __func__, config_default_dir, safe_strerror (errno)); + confp = vty_use_backup_config (config_default_dir); if (confp) { @@ -2350,7 +2356,7 @@ vty_read_config (char *config_file, fprintf (stderr, "can't open configuration file [%s]\n", config_default_dir); exit (1); - } + } } else fullpath = config_default_dir; |