Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/haad/proxychains.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Raskin <7c6f434c@mail.ru>2021-03-31 10:46:58 +0300
committerGitHub <noreply@github.com>2021-03-31 10:46:58 +0300
commit3b1aac20842facce8f8962f058b850d0f59d4e1f (patch)
treeeac9d5c7039b28a152dbf5355743b92d8f1d01d9
parent148b851d10abb2dcb36cf2b952e9bca2561081d7 (diff)
Reinitialise i before using it for iterating over dll_dirs
Previously, the value of it was kept from the loop over all the command-line arguments; as `/usr/lib` or `/lib` were far enough in the list, on many systems there was no difference, but `own_dir` and `LIB_DIR` could be ignored or not based on the argument count, which was confusing.
-rw-r--r--src/main.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/main.c b/src/main.c
index 009a352..b54a811 100644
--- a/src/main.c
+++ b/src/main.c
@@ -107,6 +107,7 @@ int main(int argc, char *argv[]) {
// search DLL
set_own_dir(argv[0]);
+ i = 0;
while(dll_dirs[i]) {
snprintf(buf, sizeof(buf), "%s/%s", dll_dirs[i], dll_name);
if(access(buf, R_OK) != -1) {