Fixed bug that getter can't get the sender's msg.
Finnaly fixed the problem,when writing to the file in unix,we should use the fflush to force the system write the buf to the file.