merge the log