Infinite loop in classes/codepage.cc
Brought to you by:
set
When running Setedit in a tty, the program gets stuck in the following loop:
../classes/codepage.cc
1851 // Adjust values found in source but not in dest (look for similars)
1852 for (i=1; i<256; i++)
1853 {
1854 unsigned val=toCode[i];
1855 if (fromCode[val])
1856 continue;
>1857 while (!fromCode[val])
1858 { // Find an equivalent for val
1859 if (val<256)
1860 val=Similar[val];
1861 else
1862 val=Similar2[val-256];
1863 }
1864 fromCode[toCode[i]]=fromCode[val];
1865 }
val is 112 and Similar[val] is also 112, so the loop never ends.
Okay, it was my fault for using a broken console font.
Feel free to close this ticket.
Last edit: magiblot 1 2020-03-31
Ok. If you have more information to help detect the broken situation and avoid the hang let me know.