diff options
author | Ambroz Bizjak <ambrop7@gmail.com> | 2014-11-12 23:52:49 +0300 |
---|---|---|
committer | Ambroz Bizjak <ambrop7@gmail.com> | 2014-11-12 23:52:49 +0300 |
commit | 65011dfa08e03ab1d29f578ce908a4c849a08465 (patch) | |
tree | 9ce022bbb0dee4033a64b06db5351dc8cf7d7c1f /misc | |
parent | 5033d556c2c7271df05ea185ade003fc94f08238 (diff) |
Fix some variable shadowing (no bugs).
Diffstat (limited to 'misc')
-rw-r--r-- | misc/find_program.h | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/misc/find_program.h b/misc/find_program.h index ecc87be..d381e18 100644 --- a/misc/find_program.h +++ b/misc/find_program.h @@ -84,16 +84,16 @@ static char * badvpn_find_program (const char *name) const char *dirs[] = {"/usr/sbin", "/usr/bin", "/sbin", "/bin", NULL}; for (size_t i = 0; dirs[i]; i++) { - char *path = concat_strings(3, dirs[i], "/", name); - if (!path) { + char *try_path = concat_strings(3, dirs[i], "/", name); + if (!try_path) { goto fail; } - if (access(path, X_OK) == 0) { - return path; + if (access(try_path, X_OK) == 0) { + return try_path; } - free(path); + free(try_path); } fail: |