mirror of
				https://github.com/rofl0r/proxychains-ng.git
				synced 2025-11-04 09:06:05 +00:00 
			
		
		
		
	Fix random_chain on Mac OS X
On Mac OS X, random chain was broken and returned always the last proxy from the config file. Use fix as suggested by @ravomavain. Closes #75.
This commit is contained in:
		@@ -464,7 +464,7 @@ static proxy_data *select_proxy(select_type how, proxy_data * pd, unsigned int p
 | 
			
		||||
		case RANDOMLY:
 | 
			
		||||
			do {
 | 
			
		||||
				k++;
 | 
			
		||||
				i = 0 + (unsigned int) (proxy_count * 1.0 * rand() / (RAND_MAX + 1.0));
 | 
			
		||||
				i = rand() % proxy_count;
 | 
			
		||||
			} while(pd[i].ps != PLAY_STATE && k < proxy_count * 100);
 | 
			
		||||
			break;
 | 
			
		||||
		case FIFOLY:
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user