mirror of
https://github.com/rofl0r/proxychains-ng.git
synced 2024-12-22 12:18:47 +00:00
print error message instead of segfaulting for invalid chain_len
closes #126
This commit is contained in:
parent
635ded3393
commit
e527b9ee64
@ -285,6 +285,10 @@ static void get_chain_data(proxy_data * pd, unsigned int *proxy_count, chain_typ
|
||||
char *pc;
|
||||
int len;
|
||||
pc = strchr(buff, '=');
|
||||
if(!pc) {
|
||||
fprintf(stderr, "error: missing equals sign '=' in chain_len directive.\n");
|
||||
exit(1);
|
||||
}
|
||||
len = atoi(++pc);
|
||||
proxychains_max_chain = (len ? len : 1);
|
||||
} else if(strstr(buff, "quiet_mode")) {
|
||||
|
Loading…
Reference in New Issue
Block a user