bail out when no proxy was configured

This commit is contained in:
rofl0r 2014-07-21 12:37:01 +02:00
parent 82d0b13b8f
commit 5168bc4eed

View File

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