if ($file =~ m/\Q$regex\E/i) ...
In reply to Re^2: Regex Mystery by harangzsolt33 in thread Regex Mystery by roho