fixed weird pointer error in cell.cpp