Added Log4r logging and fixed small bug.
Merge pull request #8 from tcnksm/issues/6

Added Log4r logging.