summaryrefslogtreecommitdiffstats
path: root/usr.sbin/mount_portalfs
diff options
context:
space:
mode:
Diffstat (limited to 'usr.sbin/mount_portalfs')
-rw-r--r--usr.sbin/mount_portalfs/mount_portalfs.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/usr.sbin/mount_portalfs/mount_portalfs.c b/usr.sbin/mount_portalfs/mount_portalfs.c
index 49a11d0..376e827 100644
--- a/usr.sbin/mount_portalfs/mount_portalfs.c
+++ b/usr.sbin/mount_portalfs/mount_portalfs.c
@@ -136,6 +136,12 @@ main(argc, argv)
* Get config file and mount point
*/
conf = argv[optind];
+ if (conf[0] != '/') {
+ (void)fprintf(stderr,
+ "The configuration file must be specified"
+ "through an absolute file path.\n");
+ exit(EX_USAGE);
+ }
/* resolve the mountpoint with realpath(3) */
(void)checkpath(argv[optind+1], mountpt);
OpenPOWER on IntegriCloud