View Single Post
  #454 (permalink)  
Old March 28th, 2014
BigJx's Avatar
BigJx BigJx is offline
WireShare Developer
 
Join Date: April 4th, 2011
Posts: 30
BigJx is a jewel in the rough
Default

I thought the following code located in components\gnutella-core\src\main\java\com\limegroup\gnutella\filters\ IPFilter.java loaded the hostiles.txt automatically if the file exits.

Code:
 
 /** Constructs an IPFilter that automatically loads the content. */
 @Inject
 public LocalIPFilter(@Named("hostileFilter") IPFilter hostileNetworkFilter, 
 @Named("backgroundExecutor") ScheduledExecutorService ipLoader) {
 this.hostileNetworkFilter = hostileNetworkFilter;
 this.ipLoader = ipLoader;
 
 File hostiles = new File(CommonUtils.getUserSettingsDir(), "hostiles.txt");
 shouldLoadHostiles = hostiles.exists();
 
 refreshHosts();
 }

Last edited by BigJx; March 28th, 2014 at 08:40 AM.
Reply With Quote