Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
When dumping a file containing some NUL characters, the display is wrong because all remaining characters on the line are replaced by NUL. This error comes from the fact that the copy of the read buffer into the line buffer is done using strncpy() which handles NUL character as end of string and pads the destination buffer with NUL afterwards. To avoid data manipulation during buffer copy, simply replace strncpy() with its memory equivalent memcpy() that does not interpret the read data. Signed-off-by: Mathieu Anquetin <mathieu.anquetin@groupe-cahors.com>
- Loading branch information