Hi there,
first of all I want to thank paxmark1 for his fast and informative reply. After looking around in several source files of Perl and Perl/Tk it was also this post, which motivated me to search the fault in my code. What a nag, since I had nearly 9000 lines of code.
I learned, there is a UNIX utility, which was not present in SparkyLinux. After installing package 'moreutils' I had a command line statement named 'isutf8' (usage: isutf8 <FileName>), which tells me, if my code file (the file where I discovered the bug) is properly encoded in UTF-8.
Unfortunately my source file went through this test. Since I had other ones from older times, I could test the isutf8 statement with them, so I finally knew, the tool is OK.
My error message was:
Malformed UTF-8 character: \xa6 (unexpected continuation byte 0xa6, with no preceding start byte) in subroutine entry at /usr/local/lib/x86_64-linux-gnu/perl/5.28.0/Tk.pm line 251.
Tk::Error: Malformed UTF-8 character (fatal) at /usr/local/lib/x86_64-linux-gnu/perl/5.28.0/Tk.pm line 251.
Tk::__ANON__ at /usr/local/lib/x86_64-linux-gnu/perl/5.28.0/Tk.pm line 251
Tk::Derived::Delegate at /usr/local/lib/x86_64-linux-gnu/perl/5.28.0/Tk/Derived.pm line 469
Tk::Widget::__ANON__ at /usr/local/lib/x86_64-linux-gnu/perl/5.28.0/Tk/Widget.pm line 322
main::SelectFindMatch at XYZ.PL line 5958
main::mnuSRFindReplace at XYZ.PL line 4006
I knew, that a malformed UTF-8 character placed in source can cause problems. I eliminated memory problems by loading a file with 11181 lines inserting my search string at the very end and case insensitive search was Ok. Then I broke my source file into peaces and after several tests I found the wrongdoer. It was an Ohm sign character, perfectly shining in the editor window within a comment line. I make heavy use of unicode in comment lines, so everything seemed to be natural; I don't remember, how I placed this character into that line (my last edit there was in february 2017, I suppose it was a cut and paste action), but obviously it was not properly encoded (though file operations with this editor are demanding unicode encoding). Deleting this character solved the problem (Notice that the bug occured some 2000 lines above line 5958 and the subroutine containing it hasn't any relation to the one which raised the faulty behaviour).
It looks like the isutf8 tool and Perl (using UTF8 which is a loose version of UTF-8) slightly disagree about encodings. Since my editor worked at least for one year precisely, containing the above mentioned character in the source, the latest Perl update seems to come with a more strict understanding of utf8 encoding.
This is another example for coincidences. On the occasion of the operating system update breaking my perl installation, I did some tests after repairing it and bang: A new problem appeared. Initally it was natural to suspect the update causing this bug too, but I had to learn, that it was my fault...