#vulnerable code 
                              public static FileSystem newFileSystem(String name) {
    String os = System.getProperty("os.name");

    Configuration config;
    if (os.contains("Windows")) {
      config = Configuration.windows();
    } else if (os.contains("OS X")) {
      config = Configuration.osX();
    } else {
      config = Configuration.unix();
    }

    return newFileSystem(name, config);
  } 
                            #location 5 
                            #vulnerability type NULL_DEREFERENCE
#fixed code
                              public static FileSystem newFileSystem(String name) {
    return newFileSystem(name, Configuration.forCurrentPlatform());
  }