2
1
mirror of https://github.com/qpdf/qpdf.git synced 2024-05-29 16:30:53 +00:00

QUtil::strcasecmp

This commit is contained in:
Jay Berkenbilt 2017-08-05 10:08:11 -04:00
parent a60eb552d3
commit 8fe261d8b4
2 changed files with 13 additions and 0 deletions

View File

@ -166,6 +166,9 @@ namespace QUtil
QPDF_DLL
std::list<std::string> read_lines_from_file(std::istream&);
QPDF_DLL
int strcasecmp(char const *, char const *);
// These routines help the tokenizer recognize certain character
// classes without using ctype, which we avoid because of locale
// considerations.

View File

@ -619,3 +619,13 @@ QUtil::read_lines_from_file(std::istream& in)
return result;
}
int
QUtil::strcasecmp(char const *s1, char const *s2)
{
#ifdef _WIN32
return _stricmp(s1, s2);
#else
return ::strcasecmp(s1, s2);
#endif
}