Fix directory creation on OSX

There are cases when mkdir(2) returns EISDIR on OSX expect and tolerate
this.

Bug: 25559586
Test: compiles, unittests pass

Change-Id: I72a467c7057d67c430c5a0d37774c93ad6c20576
diff --git a/io_delegate.cpp b/io_delegate.cpp
index caf8345..85faf67 100644
--- a/io_delegate.cpp
+++ b/io_delegate.cpp
@@ -96,7 +96,8 @@
     success = mkdir(base_dir.c_str(),
                     S_IRWXU | S_IRWXG | S_IROTH | S_IXOTH) == 0;
 #endif
-    if (!success && errno != EEXIST) {
+    // On darwin when you try to mkdir("/", ...) we get EISDIR.
+    if (!success && (errno != EEXIST && errno != EISDIR)) {
        LOG(ERROR) << "Error while creating directories: " << strerror(errno);
        return false;
     }