[ https://issues.apache.org/jira/browse/KAFKA-3940?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15375692#comment-15375692 ]
Ishita Mandhan commented on KAFKA-3940: --------------------------------------- Hi Jim, I got a notification of your PR because I had this bug assigned to me and I was working on it myself. I reviewed your PR and I think the fix would be more involved and more occurrences of dir.mkdirs() and File.delete could be addressed as discussed above. What are your thoughts? Do you mind collaborating on this patch set? > Log should check the return value of dir.mkdirs() > ------------------------------------------------- > > Key: KAFKA-3940 > URL: https://issues.apache.org/jira/browse/KAFKA-3940 > Project: Kafka > Issue Type: Bug > Components: log > Affects Versions: 0.10.0.0 > Reporter: Jun Rao > Assignee: Ishita Mandhan > Labels: newbie > > In Log.loadSegments(), we call dir.mkdirs() w/o checking the return value and > just assume the directory will exist after the call. However, if the > directory can't be created (e.g. due to no space), we will hit > NullPointerException in the next statement, which will be confusing. > for(file <- dir.listFiles if file.isFile) { -- This message was sent by Atlassian JIRA (v6.3.4#6332)