Remove a number of unused variables, no bug
Backed out changeset a73ffb0d0c97 because of build bustage