mirror of
https://github.com/tesseract-ocr/tesseract.git
synced 2025-08-06 13:56:47 +08:00
Changed several printfs to tprintfs to prevent stdout pollution.
git-svn-id: https://tesseract-ocr.googlecode.com/svn/trunk@23 d0cd1f9f-072b-0410-8dd7-cf729c803f20
This commit is contained in:
parent
fcfaafd602
commit
f1ce0ecd7f
@ -83,7 +83,7 @@ DLLSYM PAGE_BLOCK_LIST *read_poly_blocks( //read file
|
||||
page_block_it.set_to_list (pb_list);
|
||||
number_of_pblocks = pb_list->length ();
|
||||
|
||||
printf ("%d page blocks read\n", number_of_pblocks);
|
||||
tprintf ("%d page blocks read\n", number_of_pblocks);
|
||||
return pb_list;
|
||||
|
||||
}
|
||||
|
@ -170,7 +170,7 @@ double streamtofloat(FILE* s)
|
||||
k *= 10;
|
||||
}
|
||||
} else if (c == 'e' || c == 'E')
|
||||
printf("WARNING: Scientific Notation not supported!");
|
||||
tprintf("WARNING: Scientific Notation not supported!");
|
||||
|
||||
ungetc(c, s);
|
||||
double f = static_cast<double>(v)
|
||||
@ -204,7 +204,7 @@ double strtofloat(const char* s)
|
||||
k *= 10;
|
||||
}
|
||||
} else if (*s == 'e' || *s == 'E')
|
||||
printf("WARNING: Scientific Notation not supported!");
|
||||
tprintf("WARNING: Scientific Notation not supported!");
|
||||
|
||||
double f = static_cast<double>(v)
|
||||
+ static_cast<double>(w) / static_cast<double>(k);
|
||||
|
@ -627,7 +627,7 @@ LIST AdaptiveClassifier(TBLOB *Blob, TBLOB *DotBlob, TEXTROW *Row) {
|
||||
NumClassesOutput += count (Choices);
|
||||
if (Choices == NIL) {
|
||||
if (!bln_numericmode)
|
||||
printf ("Nil classification!\n"); // Should never normally happen.
|
||||
tprintf ("Nil classification!\n"); // Should never normally happen.
|
||||
return (append_choice (NIL, "", 50.0f, -20.0f, -1));
|
||||
}
|
||||
|
||||
|
@ -40,6 +40,7 @@ Import original HP distribution
|
||||
**/
|
||||
|
||||
#include "cutil.h"
|
||||
#include "tprintf.h"
|
||||
#include "callcpp.h"
|
||||
|
||||
#include <stdlib.h>
|
||||
@ -85,7 +86,7 @@ long long_rand(long limit) {
|
||||
FILE *open_file(const char *filename, const char *mode) {
|
||||
FILE *thisfile = NULL;
|
||||
if ((thisfile = fopen (filename, mode)) == NULL) {
|
||||
printf ("Could not open file, %s\n", filename);
|
||||
tprintf ("Could not open file, %s\n", filename);
|
||||
exit (1);
|
||||
}
|
||||
return (thisfile);
|
||||
|
Loading…
Reference in New Issue
Block a user