Fix "this"
Fix not writing closed files