pulling in this small bug fix from https://github.com/apache/kafka/pull/1265/files#diff-8736b7fd8ad077ea55ea2a8ad61285faR99