Small changes. Compatibility with java 1.6.