Eliminating warnings

Fixing some unmatched signed/unsigned types and unused variables.