catch double close error