Modify write.c