Restrict max blocksize to [1,2,3].

git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@8401 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
This commit is contained in:
Steven Franke 2018-01-11 23:49:03 +00:00
parent fc6389d3ce
commit ae5e00d83c

View File

@ -694,7 +694,7 @@ void usage(void)
printf("\n"); printf("\n");
printf("Options:\n"); printf("Options:\n");
printf(" -a <path> path to writeable data files, default=\".\"\n"); printf(" -a <path> path to writeable data files, default=\".\"\n");
printf(" -b x (sequence estimator block size; 1,2,3,6, or 9)\n"); printf(" -b x (sequence estimator block size; 1,2,3)\n");
printf(" -c write .c2 file at the end of the first pass\n"); printf(" -c write .c2 file at the end of the first pass\n");
printf(" -C maximum number of decoder cycles per bit, default 10000\n"); printf(" -C maximum number of decoder cycles per bit, default 10000\n");
printf(" -d deeper search. Slower, a few more decodes\n"); printf(" -d deeper search. Slower, a few more decodes\n");
@ -797,6 +797,10 @@ int main(int argc, char *argv[])
break; break;
case 'b': case 'b':
nblocksize=(int) atoi(optarg); nblocksize=(int) atoi(optarg);
if( nblocksize < 1 || nblocksize > 3 ) {
usage();
return 1;
}
break; break;
case 'c': case 'c':
writec2=1; writec2=1;