small cleanups to avoid a few ifdef _WIN32

This commit is contained in:
Jean-Francois Dockes
2022-01-17 15:46:40 +01:00
parent f0efed545d
commit b118c93b4f
14 changed files with 671 additions and 648 deletions
+1 -1
View File
@@ -1,4 +1,4 @@
/* Copyright (C) 2004 J.F.Dockes
/* Copyright (C) 2004-2022 J.F.Dockes
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
+1 -4
View File
@@ -69,11 +69,9 @@ bool MimeHandlerText::set_document_file_impl(const string&, const string &fn)
return false;
}
#ifndef _WIN32
// Check for charset defined in extended attribute as per:
// http://freedesktop.org/wiki/CommonExtendedAttributes
pxattr::get(m_fn, "charset", &m_charsetfromxattr);
#endif
getparams();
if (m_maxmbs != -1 && m_totlen / (1024*1024) > m_maxmbs) {
@@ -88,8 +86,7 @@ bool MimeHandlerText::set_document_file_impl(const string&, const string &fn)
return true;
}
bool MimeHandlerText::set_document_string_impl(const string&,
const string& otext)
bool MimeHandlerText::set_document_string_impl(const string&, const string& otext)
{
m_fn.clear();
m_totlen = otext.size();