diff --git a/src/api/pdfrenderer.cpp b/src/api/pdfrenderer.cpp index aa16f2a1bd..99e114d28b 100644 --- a/src/api/pdfrenderer.cpp +++ b/src/api/pdfrenderer.cpp @@ -305,7 +305,7 @@ static void ClipBaseline(int ppi, int x1, int y1, int x2, int y2, *line_y1 = *line_y2 = (y1 + y2) / 2; } -bool CodepointToUtf16be(int code, char utf16[kMaxBytesPerCodepoint]) { +static bool CodepointToUtf16be(int code, char utf16[kMaxBytesPerCodepoint]) { if ((code > 0xD7FF && code < 0xE000) || code > 0x10FFFF) { tprintf("Dropping invalid codepoint %d\n", code); return false; @@ -841,7 +841,7 @@ bool TessPDFRenderer::AddImageHandler(TessBaseAPI* api) { char buf[kBasicBufSize]; char buf2[kBasicBufSize]; Pix *pix = api->GetInputImage(); - const char* filename = reinterpret_cast(api->GetInputName()); + const char* filename = api->GetInputName(); int ppi = api->GetSourceYResolution(); if (!pix || ppi <= 0) return false; diff --git a/src/viewer/scrollview.cpp b/src/viewer/scrollview.cpp index 955215a876..5fdf88a357 100644 --- a/src/viewer/scrollview.cpp +++ b/src/viewer/scrollview.cpp @@ -184,7 +184,7 @@ void* ScrollView::MessageReceiver(void* a) { } // Table to implement the color index values in the old system. -int table_colors[ScrollView::GREEN_YELLOW+1][4]= { +static const uint8_t table_colors[ScrollView::GREEN_YELLOW+1][4]= { {0, 0, 0, 0}, // NONE (transparent) {0, 0, 0, 255}, // BLACK. {255, 255, 255, 255}, // WHITE.