That gives you one copy of each distinct line. The OP wanted only the lines that appear exactly once. It could be done with uniq -c and grep and cut, but it gets to the point that you just want to do it in Perl.
Gar. Should have double-checked that -u option. Good answer.
Caution: Contents may have been coded under pressure.