bail out when no proxy was configured

pull/37/merge
rofl0r 2014-07-21 12:37:01 +02:00
parent 82d0b13b8f
commit 5168bc4eed
1 changed files with 4 additions and 0 deletions

View File

@ -291,6 +291,10 @@ static void get_chain_data(proxy_data * pd, unsigned int *proxy_count, chain_typ
}
}
fclose(file);
if(!count) {
fprintf(stderr, "error: no valid proxy found in config\n");
exit(1);
}
*proxy_count = count;
proxychains_got_chain_data = 1;
}