Removed unused code.
Modified to mitigate compiler warnings.