in reply to Re: Doesn't work in Cygwin
in thread Doesn't work in Cygwin
to completely get rid of LF and CR characters.tr/\r\n//d
Furthermore, you check for duplicates with
which is an extremely poor ways to handle this kind of things. It won't match if unexpectedly $randomized_entry contains meta characters, it's prone to crashes if it doesn't actually look like a valid regexp, and it'll give you false positives when for example $randomized_entry contains "foo", and $list_to_match contains "if music be the food of love".if ($list_to_match =~ /$randomized_entry/)
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: Doesn't work in Cygwin
by maybeD (Sexton) on Nov 16, 2005 at 12:58 UTC | |
by bart (Canon) on Nov 16, 2005 at 17:17 UTC |