properly report close errors