#vulnerable code 
                              @Override
  public WatchService newWatchService() throws IOException {
    return new PollingWatchService(defaultView, pathService, fileStore.state());
  } 
                            #location 3 
                            #vulnerability type RESOURCE_LEAK
#fixed code
                              @Override
  public WatchService newWatchService() throws IOException {
    return watchServiceConfig.newWatchService(defaultView, pathService);
  }