Don't accept generated temp directory names that can't be created successfully.

This commit is contained in:
Charles Reiss 2013-03-19 15:08:22 -07:00
parent aa8fe1a209
commit c847dd3da2

View file

@ -168,8 +168,7 @@ private class DiskStore(blockManager: BlockManager, rootDirs: String)
localDirId = "%s-%04x".format(dateFormat.format(new Date), rand.nextInt(65536))
localDir = new File(rootDir, "spark-local-" + localDirId)
if (!localDir.exists) {
localDir.mkdirs()
foundLocalDir = true
foundLocalDir = localDir.mkdirs()
}
} catch {
case e: Exception =>