Housekeeping and refactoring. Correcting some warnings.