For the same reasons it's used in libzfs_init(), this was just
overlooked because zinject gets minimal use.
Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Issue #1498
+#ifdef HAVE_SETMNTENT
+ if ((fp = setmntent(MNTTAB, "r")) == NULL) {
+#else
if ((fp = fopen(MNTTAB, "r")) == NULL) {
if ((fp = fopen(MNTTAB, "r")) == NULL) {
(void) fprintf(stderr, "cannot open /etc/mtab\n");
return (-1);
}
(void) fprintf(stderr, "cannot open /etc/mtab\n");
return (-1);
}