--- old/src/hotspot/os/solaris/os_solaris.cpp 2018-07-10 15:42:59.322495310 -0400 +++ new/src/hotspot/os/solaris/os_solaris.cpp 2018-07-10 15:42:59.102483191 -0400 @@ -4306,9 +4306,7 @@ // Scan the directory bool result = true; - char buf[sizeof(struct dirent) + MAX_PATH]; - struct dirent *dbuf = (struct dirent *) buf; - while (result && (ptr = readdir(dir, dbuf)) != NULL) { + while (result && (ptr = readdir(dir)) != NULL) { if (strcmp(ptr->d_name, ".") != 0 && strcmp(ptr->d_name, "..") != 0) { result = false; }