chiark / gitweb /
Fix "In" not to be in lowercase set
[ypp-sc-tools.db-test.git] / pctb / convert.c
index eb7536d6fac4bcc3014f2b7c35880602febc3820..75c70804df7b7d4632e9ee9967540f873c21d313 100644 (file)
@@ -51,6 +51,7 @@ static char *o_screenshot_fn;
 static int o_single_page, o_quiet;
 static const char *o_outputmode= "upload";
 
+const char *o_resolver;
 FILE *screenshot_file;
 
 
@@ -77,6 +78,10 @@ static void run_analysis(void) {
   progress("running recognition...");
   analyse(tf);
 
+  if (o_single_page && !strcmp(o_outputmode,"upload"))
+    fatal("Recognition successful, but refusing to upload partial data\n"
+         " (--single-page specified).  Specify an output mode?");
+
   sysassert( fseek(tf,0,SEEK_SET) == 0);
 
   progress_log("processing results (--%s)...", o_outputmode);
@@ -116,6 +121,8 @@ int main(int argc, char **argv) {
       o_single_page= 1;
     else if (!strcmp(arg,"--quiet"))
       o_quiet= 1;
+    else if (!strcmp(arg,"--edit-charset"))
+      o_resolver= "./yppsc-ocr-resolver";
     else if (!strcmp(arg,"--raw-tsv"))
       o_outputmode= 0;
     else if (!strcmp(arg,"--upload") ||