cleanup fsimain