Merge "init: fix write_file checkreqprot logic error"