@@ -1047,17 +1047,17 @@ void repack_if_alldigits(char *input,int aonly)
10471047 if (alldigits && dotpos && s>dotpos) // e is last char, s is one before, both are beyond dot, all characters are digits
10481048 {
10491049 if (aonly) // v1.50 - encode only using the letter A
1050- {
1050+ {
10511051 int v = ((*input)-'0')*100 + ((*s)-'0')*10 + ((*e)-'0');
10521052 *input='A';
10531053 *s = encode_chars[v/32];
10541054 *e = encode_chars[v%32];
1055- }
1055+ }
10561056 else // encode using A,E,U
1057- {
1057+ {
10581058 int v = ((*s)-'0') *10 + ((*e)-'0');
10591059 *s = encode_chars[(v/34)+31];
1060- *e = encode_chars[v%34];
1060+ *e = encode_chars[v%34];
10611061 }
10621062 }
10631063}
@@ -1066,14 +1066,14 @@ int unpack_if_alldigits(char *input) // returns 1 if unpacked, 0 if left unchang
10661066{ // rewrite all-digit codes
10671067 char *s=input;
10681068 char *dotpos=NULL;
1069- int aonly=(*s=='A' || *s=='a'); if (aonly) s++; //*** v1.50
1070- for (;*s!=0 && s[2]!=0 && s[2]!='-';s++)
1069+ int aonly=(*s=='A' || *s=='a'); if (aonly) s++; //*** v1.50
1070+ for (;*s!=0 && s[2]!=0 && s[2]!='-';s++)
10711071 {
1072- if (*s=='-')
1073- break;
1074- else if (*s=='.' && !dotpos)
1075- dotpos=s;
1076- else if ( decode_chars[*s]<0 || decode_chars[*s]>9 )
1072+ if (*s=='-')
1073+ break;
1074+ else if (*s=='.' && !dotpos)
1075+ dotpos=s;
1076+ else if ( decode_chars[*s]<0 || decode_chars[*s]>9 )
10771077 return 0; // nondigit, so stop
10781078 }
10791079
@@ -1305,8 +1305,8 @@ int master_decode( long *nx,long *ny, // <- store result in nx,ny
13051305
13061306 // debug support: U-lead pre-processing
13071307 if (*input=='u' || *input=='U') {
1308- strcpy(input,input+1);
1309- ilen--;
1308+ strcpy(input,input+1);
1309+ ilen--;
13101310 voweled=1;
13111311 }
13121312
@@ -1318,7 +1318,7 @@ int master_decode( long *nx,long *ny, // <- store result in nx,ny
13181318 const char *s=input;
13191319 for ( ; *s!=0; s++ )
13201320 {
1321- if (*s=='.')
1321+ if (*s=='.')
13221322 { if (dot) return -5; else dot=s; }
13231323 else if ( decode_chars[*s]<0 )
13241324 return -4; // invalid char
@@ -2132,7 +2132,7 @@ static struct { UWORD min; UWORD max; const char *convert; } unicode2asc[] =
21322132 {0x0410,0x042f,"AZBGDEFNI?KLMHOJPCTYQXSVW????U?R"}, // Cyrillic
21332133 {0x05d0,0x05ea,"ABCDFIGHJKLMNPQ?ROSETUVWXYZ"}, // Hebrew
21342134 {0x0905,0x0939,"A?????????E?????B?CD?F?G??HJZ?KL?MNP?QU?RS?T?V??W??XY"}, // Hindi
2135- {0x0d07,0x0d39,"I?U?E??????A??BCD??F?G??HOJ??KLMNP?????Q?RST?VWX?YZ"}, // Malai
2135+ {0x0d07,0x0d39,"I?U?E??????A??BCD??F?G??HOJ??KLMNP?????Q?RST?VWX?YZ"}, // Malay
21362136 {0x10a0,0x10bf,"AB?CE?D?UF?GHOJ?KLMINPQRSTVW?XYZ"}, // Georgisch
21372137 {0x30a2,0x30f2,"A?I?O?U?EB?C?D?F?G?H???J???????K??????L?M?N?????P??Q??R??S?????TV?????WX???Y????Z"}, // Katakana
21382138 {0x0e01,0x0e32,"BC?D??FGHJ??O???K??L?MNP?Q?R????S?T?V?W????UXYZAIE"}, // Thai
@@ -2591,7 +2591,7 @@ const UWORD* encodeToAlphabet(const char *mapcode,int alphabet) // 0=roman, 2=cy
25912591 if ( asc2lan[alphabet][4]==0x003f ) // alphabet has no letter E
25922592 if ( strchr(mapcode,'E') || strchr(mapcode,'U') || strchr(mapcode,'e') || strchr(mapcode,'u') ) // v1.50 get rid of E and U
25932593 {
2594- char u[16];
2594+ char u[16];
25952595 strcpy(u,mapcode);
25962596 unpack_if_alldigits(u);
25972597 repack_if_alldigits(u,1);
0 commit comments