The discount chain Big Lots has reached a deal that will keep hundreds of its stores open. Big Lots said it will be sold to Gordon Brothers Retail Partners, which specializes in distressed companies.