public static File maybeMarkUnwritable(File path)
    {
        File directory = getDirectory(path);
        if (instance.unwritableDirectories.add(directory))
        {
            logger.warn("Blacklisting {} for writes", directory);
            return directory;
        }
        return null;
    }
public static File maybeMarkUnwritable ( File path ) { File directory = getDirectory ( path ) ; if ( instance . unwritableDirectories . add ( directory ) ) { logger . warn ( "Blacklisting {} for writes" , directory ) ; return directory ; } return null ; }
Adds parent directory of the file (or the file itself, if it is a directory)
to the set of unwritable directories.

@return the blacklisted directory or null if nothing has been added to the list.