diff --git a/cmd/mount_zfs/mount_zfs.c b/cmd/mount_zfs/mount_zfs.c index e3e8cfc220..2fb4d65e92 100644 --- a/cmd/mount_zfs/mount_zfs.c +++ b/cmd/mount_zfs/mount_zfs.c @@ -32,6 +32,7 @@ #include #include #include +#include #define ZS_COMMENT 0x00000000 /* comment */ #define ZS_ZFSUTIL 0x00000001 /* caller is zfs(8) */ @@ -387,7 +388,7 @@ main(int argc, char **argv) opterr = 0; /* check options */ - while ((c = getopt(argc, argv, "sfnvo:h?")) != -1) { + while ((c = getopt_long(argc, argv, "sfnvo:h?", 0, 0)) != -1) { switch (c) { case 's': sloppy = 1;