summaryrefslogtreecommitdiff
path: root/ospf6d
diff options
context:
space:
mode:
Diffstat (limited to 'ospf6d')
-rw-r--r--ospf6d/ospf6_main.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/ospf6d/ospf6_main.c b/ospf6d/ospf6_main.c
index c4b9124e..d40bd97f 100644
--- a/ospf6d/ospf6_main.c
+++ b/ospf6d/ospf6_main.c
@@ -291,6 +291,13 @@ main (int argc, char *argv[], char *envp[])
}
}
+ if (geteuid () != 0)
+ {
+ errno = EPERM;
+ perror (progname);
+ exit (1);
+ }
+
/* thread master */
master = thread_master_create ();