Probably the best approach would be to do a proper system-to-system transfer in the first place. (Update: On second thought, see below for probable BP.) E.g., the ftp utility common to most (all?) OSen has an ascii mode (automatic line-end translation) as well as a binary (don't touch nuthin') mode.
Otherwise, doing something like
$line =~ s{ [\x0d\x0a]+ \z }{}xms;
to each and every line would do the trick to eliminate any possible combination of \x0d and \x0a characters from the end of the line. Other regexes can handle more particular combinations of line-enders.