Fixed static analysis errors.