A colleague with Tcl and Ksh wrote a program, use for an operation, if there is error to write the error message to a file, write method is 2> $stderr, and then judge the size of the file, if greater than 0, then think that there is a mistake, error.
It is strange that the program has not been successfully executed and has been an error. Colleagues tracked his code line by row, and found that the file $stderr was just created with a size of 0, but after a while he will become 1byte. However, when you open the view, the contents of the file are empty. Later, vi in accordance with the 16 into the system opened (:%!XXD), found 0a.
0X0A is the default line terminator (EOL) under UNIX, which is available in every row. We experimented with using print to create a file under Unix:
Print $test > Test
Where $test is an undefined variable, a file of size 1byte is generated. Open the file, you can also find the existence of 0a.
However, if the C language to write a file operation function, but can get a size of 0 and opened after the 0a file. It's strange ...