Although the Gap Procedure that Brams and Kilgour (2001) proposed for determining the price of each room in the housemates problem has many favorable properties, it also has one drawback: Its solution is not always envy-free. Described herein is an approach that uses linear programming to find an envy-free solution closest (in a certain sense) to the Gap solution when the latter is not envy-free. If negative prices are allowed, such a solution always exists. If not, it sometimes exists, in which case linear programming can find it by disallowing negative prices. Several examples are presented.