SPARK-1656: Fix potential resource leaks

JIRA: https://issues.apache.org/jira/browse/SPARK-1656
The previous codes are:
```scala
1    try {
2     blockManager.dataSerializeStream(blockId, outputStream, values)
3      outputStream.close()
4    } catch {
5      case e: Throwable => {
6        outputStream.close()
7        if(file.exists()) {
8          file.delete()
9        }
10        throw e
11      }
12   }
```
My concern is if L6 outputStream.close() throws an exception, `if(file.exists()) { file.delete() }` won't be executed. So I changed to the nested `try`s.