File tree Expand file tree Collapse file tree 2 files changed +7
-7
lines changed
core/src/main/scala/org/apache/spark Expand file tree Collapse file tree 2 files changed +7
-7
lines changed Original file line number Diff line number Diff line change @@ -219,12 +219,12 @@ private[spark] object HttpBroadcast extends Logging {
219219
220220 private def deleteBroadcastFile (file : File ) {
221221 try {
222- if (! file.exists) {
223- logWarning( " Broadcast file to be deleted does not exist: %s " .format(file))
224- } else if ( file.delete()) {
225- logInfo( " Deleted broadcast file: %s " .format(file))
226- } else {
227- logWarning( " Could not delete broadcast file: %s " .format(file))
222+ if (file.exists) {
223+ if ( file.delete()) {
224+ logInfo( " Deleted broadcast file: %s " .format(file))
225+ } else {
226+ logWarning( " Could not delete broadcast file: %s " .format(file))
227+ }
228228 }
229229 } catch {
230230 case e : Exception =>
Original file line number Diff line number Diff line change @@ -209,7 +209,7 @@ private[spark] class BlockManager(
209209 }
210210 }
211211
212- /** Get the BlockStatus for the block identified by the given ID, if it exists.*/
212+ /** Get the BlockStatus for the block identified by the given ID, if it exists. */
213213 def getStatus (blockId : BlockId ): Option [BlockStatus ] = {
214214 blockInfo.get(blockId).map { info =>
215215 val memSize = if (memoryStore.contains(blockId)) memoryStore.getSize(blockId) else 0L
You can’t perform that action at this time.
0 commit comments