summaryrefslogtreecommitdiffstats
path: root/contrib/file/src/readcdf.c
diff options
context:
space:
mode:
authorRenato Botelho <renato@netgate.com>2016-05-09 17:39:11 -0300
committerRenato Botelho <renato@netgate.com>2016-05-09 17:39:11 -0300
commiteb1aa95459d780e1328d821fd6af261c2221a62b (patch)
treed0c75db0de1902022252ffee3acbfe775366214c /contrib/file/src/readcdf.c
parent4a578420216361b8acfb7296dd0b68c805e5121b (diff)
parent1708fafa25d9413ab466d3670d803e2ebf885d45 (diff)
downloadFreeBSD-src-eb1aa95459d780e1328d821fd6af261c2221a62b.zip
FreeBSD-src-eb1aa95459d780e1328d821fd6af261c2221a62b.tar.gz
Merge remote-tracking branch 'origin/stable/10' into devel
Diffstat (limited to 'contrib/file/src/readcdf.c')
-rw-r--r--contrib/file/src/readcdf.c12
1 files changed, 2 insertions, 10 deletions
diff --git a/contrib/file/src/readcdf.c b/contrib/file/src/readcdf.c
index f79ac99..99d8ec0 100644
--- a/contrib/file/src/readcdf.c
+++ b/contrib/file/src/readcdf.c
@@ -26,7 +26,7 @@
#include "file.h"
#ifndef lint
-FILE_RCSID("@(#)$File: readcdf.c,v 1.56 2016/03/03 22:20:03 christos Exp $")
+FILE_RCSID("@(#)$File: readcdf.c,v 1.53 2015/04/09 20:01:41 christos Exp $")
#endif
#include <assert.h>
@@ -60,16 +60,12 @@ static const struct nv {
{ "Windows Installer", "vnd.ms-msi", },
{ NULL, NULL, },
}, name2mime[] = {
- { "Book", "vnd.ms-excel", },
- { "Workbook", "vnd.ms-excel", },
{ "WordDocument", "msword", },
{ "PowerPoint", "vnd.ms-powerpoint", },
{ "DigitalSignature", "vnd.ms-msi", },
{ NULL, NULL, },
}, name2desc[] = {
- { "Book", "Microsoft Excel", },
- { "Workbook", "Microsoft Excel", },
- { "WordDocument", "Microsoft Word", },
+ { "WordDocument", "Microsoft Office Word",},
{ "PowerPoint", "Microsoft PowerPoint", },
{ "DigitalSignature", "Microsoft Installer", },
{ NULL, NULL, },
@@ -123,8 +119,6 @@ cdf_app_to_mime(const char *vbuf, const struct nv *nv)
assert(c_lc_ctype != NULL);
old_lc_ctype = uselocale(c_lc_ctype);
assert(old_lc_ctype != NULL);
-#else
- char *old_lc_ctype = setlocale(LC_CTYPE, "C");
#endif
for (i = 0; nv[i].pattern != NULL; i++)
if (strcasestr(vbuf, nv[i].pattern) != NULL) {
@@ -137,8 +131,6 @@ cdf_app_to_mime(const char *vbuf, const struct nv *nv)
#ifdef USE_C_LOCALE
(void)uselocale(old_lc_ctype);
freelocale(c_lc_ctype);
-#else
- setlocale(LC_CTYPE, old_lc_ctype);
#endif
return rv;
}
OpenPOWER on IntegriCloud