preserve error code returned from read and write
name conflict