Problem with sed converting convert DOS newlines (CR/LF) to Unix format (sed version 3.02+))

Aachen Panoramen <[email protected]>
Newsgroups gmane.editors.sed.user
Message-ID <[email protected]>
Hello, 


I was using the following sed commands

s/.$//;
s/^M$//;


to replace DOS newlines (CR/LF) to Unix format in the following DOS text file (without --):
--

Hello
World
Hello
sed

--

With sed version 3.02 all was fine.
Yesterday I updated to version 4.21 and this conversion doesn't work any more.

I tried other version too and found that it doesn't work any more since version 3.02.80.

The result of sed version 4.09 - 4.21 is:
--

Hell
Worl
Hell
se
--


The result of 3.02.80 and 4.06 is an empty file.


Can anyone help me with this problem?
Thanks,
Andreas.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.