Mar 2, 2015, 10:02 AM
Post #2 of 2
I strongly suspect that your input file has been prepared under Windows ans is used under Linux.
Re: [sumit2606] "?" added at the end of dir on Linux Server
[In reply to]
Windows lines end with "\r\n" and Unix lines end with "\n" only.
If your was prepared under Windows and is processed in Perl under Unix, the chomp function will only remove "\n", thus leaving the "\r".
Try to replace the chomp with a regular expression such as: