fix 2 clang warnings

This commit is contained in:
zdenop 2018-12-30 20:25:24 +01:00
parent cb049133cd
commit d3065520fa
2 changed files with 2 additions and 2 deletions

View File

@ -71,10 +71,10 @@ endif()
if (WIN32)
if (MSVC)
add_definitions(-D_CRT_SECURE_NO_WARNINGS)
add_definitions(-DNOMINMAX)
if (CLANG)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Xclang -fopenmp /utf-8")
else()
add_definitions(-DNOMINMAX)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /MP /openmp /utf-8")
endif()
endif()

View File

@ -1988,7 +1988,7 @@ bool TessBaseAPI::Threshold(Pix** pix) {
pixDestroy(pix);
// Zero resolution messes up the algorithms, so make sure it is credible.
int user_dpi = 0;
bool a = GetIntVariable("user_defined_dpi", &user_dpi);
GetIntVariable("user_defined_dpi", &user_dpi);
int y_res = thresholder_->GetScaledYResolution();
if (user_dpi && (user_dpi < kMinCredibleResolution ||
user_dpi > kMaxCredibleResolution)) {