cleanup hcwin code