summaryrefslogtreecommitdiffstats
path: root/ospf6d/ospf6_main.c
diff options
context:
space:
mode:
Diffstat (limited to 'ospf6d/ospf6_main.c')
-rw-r--r--ospf6d/ospf6_main.c23
1 files changed, 13 insertions, 10 deletions
diff --git a/ospf6d/ospf6_main.c b/ospf6d/ospf6_main.c
index 800fae4b..cd00fa86 100644
--- a/ospf6d/ospf6_main.c
+++ b/ospf6d/ospf6_main.c
@@ -14,13 +14,14 @@
* General Public License for more details.
*
* You should have received a copy of the GNU General Public License
- * along with GNU Zebra; see the file COPYING. If not, write to the
- * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
- * Boston, MA 02111-1307, USA.
+ * along with GNU Zebra; see the file COPYING. If not, write to the
+ * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+ * Boston, MA 02111-1307, USA.
*/
#include <zebra.h>
#include <lib/version.h>
+#include <lib/zclient.h>
#include "getopt.h"
#include "thread.h"
@@ -36,6 +37,8 @@
#include "sigevent.h"
#include "ospf6d.h"
+#include "ospf6_asbr.h"
+#include "ospf6_message.h"
/* Default configuration file name for ospf6d. */
#define OSPF6_DEFAULT_CONFIG "ospf6d.conf"
@@ -67,7 +70,7 @@ struct zebra_privs_t ospf6d_privs =
};
/* ospf6d options, we use GNU getopt library. */
-struct option longopts[] =
+struct option longopts[] =
{
{ "daemon", no_argument, NULL, 'd'},
{ "config_file", required_argument, NULL, 'f'},
@@ -104,7 +107,7 @@ usage (char *progname, int status)
if (status != 0)
fprintf (stderr, "Try `%s --help' for more information.\n", progname);
else
- {
+ {
printf ("Usage : %s [OPTION...]\n\n\
Daemon which manages OSPF version 3.\n\n\
-d, --daemon Runs in daemon mode\n\
@@ -154,7 +157,7 @@ ospf6_exit (int status)
}
/* SIGHUP handler. */
-static void
+static void
sighup (void)
{
zlog_info ("SIGHUP received");
@@ -224,14 +227,14 @@ main (int argc, char *argv[], char *envp[])
progname = ((p = strrchr (argv[0], '/')) ? ++p : argv[0]);
/* Command line argument treatment. */
- while (1)
+ while (1)
{
opt = getopt_long (argc, argv, "df:i:hp:A:P:u:g:vC", longopts, 0);
-
+
if (opt == EOF)
break;
- switch (opt)
+ switch (opt)
{
case 0:
break;
@@ -310,7 +313,7 @@ main (int argc, char *argv[], char *envp[])
/* Start execution only if not in dry-run mode */
if (dryrun)
return(0);
-
+
if (daemon_mode && daemon (0, 0) < 0)
{
zlog_err("OSPF6d daemon failed: %s", strerror(errno));