aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorGravatar Sijmen J. Mulder <ik@sjmulder.nl>2020-06-01 03:17:03 +0200
committerGravatar GitHub <noreply@github.com>2020-06-01 06:47:03 +0530
commit68b9185071632d9afe8dba1b32bc40ba25b9b301 (patch)
treecb7df41cca3d324a81ddb73d738c50d34208ba18 /src
parentf5b5cf5fd71fb7a5286cc0c427fa2462bd4b7ad3 (diff)
downloadnnn-68b9185071632d9afe8dba1b32bc40ba25b9b301.tar.gz
Wrap FILE_MIME_OPTS use in check (#622)
We leave it undefined on Solaris/Illumos because no such options exist, so only use it if we have it.
Diffstat (limited to 'src')
-rw-r--r--src/nnn.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/nnn.c b/src/nnn.c
index af3f4fe..493a920 100644
--- a/src/nnn.c
+++ b/src/nnn.c
@@ -3698,9 +3698,11 @@ static bool show_stats(const char *fpath, const struct stat *sb)
}
fprintf(fp, " %s\n ", begin);
+#ifdef FILE_MIME_OPTS
/* Show the file mime type */
get_output(g_buf, CMD_LEN_MAX, "file", FILE_MIME_OPTS, fpath, FALSE);
fprintf(fp, "%s", g_buf);
+#endif
}
}