diff options
author | David Sommerseth <davids@redhat.com> | 2011-12-02 16:32:56 +0100 |
---|---|---|
committer | David Sommerseth <davids@redhat.com> | 2011-12-05 11:35:28 +0100 |
commit | 870cf166add7ea0aa15c9d12b7916e669a9f441f (patch) | |
tree | 0bfcd62341a2d093e852be0900c47363ffe859ff /options.c | |
parent | e7d1ac82f9a21ef91030e4f104d4ef0810b07f8e (diff) | |
download | openvpn-870cf166add7ea0aa15c9d12b7916e669a9f441f.tar.gz openvpn-870cf166add7ea0aa15c9d12b7916e669a9f441f.tar.xz openvpn-870cf166add7ea0aa15c9d12b7916e669a9f441f.zip |
Don't look for 'stdin' file when using --auth-user-pass
This argument allows the keyword 'stdin' to indicate that the input
is to be read from the stdin. Don't check for file existence if the
file name is set to 'stdin'
Signed-off-by: David Sommerseth <davids@redhat.com>
Acked-by: Gert Doering <gert@greenie.muc.de>
Diffstat (limited to 'options.c')
-rw-r--r-- | options.c | 5 |
1 files changed, 3 insertions, 2 deletions
@@ -2688,8 +2688,9 @@ options_postprocess_filechecks (struct options *options) errs |= check_file_access (CHKACC_FILE, options->management_user_pass, R_OK, "--management user/password file"); #endif /* ENABLE_MANAGEMENT */ - errs |= check_file_access (CHKACC_FILE, options->auth_user_pass_file, R_OK, - "--auth-user-pass"); + if( options->auth_user_pass_file && strcmp(options->auth_user_pass_file, "stdin") != 0 ) + errs |= check_file_access (CHKACC_FILE, options->auth_user_pass_file, R_OK, + "--auth-user-pass"); /* ** System related ** */ |