Bug with JAVA CRLF
807600Dec 1 2007 — edited Dec 21 2007When a sequence of bytes read from a file and if the sequence of bytes has LF then JAVA adds a CR before the LF. That is LF is converted into CRLF combination. If the sequence of byte is then converted into HEX string it shows 0A (LF) only but with bytes it is having CRLF. I am experiencing this problem while reading a sequence of bytes from file which has to be sent to a device connected to SERIAL port. The device checks for CRC and it does not match with the actual contents becuase of this LF is converted in to CRLF. I am eperiencing this problem in Linux only and not in the case of Windows. Please help me sort out this problem. I don't know whether this is a bug with JAVA. Please give me solution.