refs.c: remove the update_ref_write function