fixed cleanup of GDI