Switching to use try-with-resources

The Closeables.closeQuietly(Closeable) method is no longer
present in v18. This change replaces usages with the
try-with-resource pattern.

This is part of the work to upgrade Guava to version 18.

Cherry picked f43973fd13262553b497cd83f4ea9654a72ff22f

BUG: 19672715
Change-Id: I469bef916e3c570454dae19d5dc4515143ee4cdb
1 file changed