[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: svn commit: r1678734 - in /subversion/trunk/subversion: include/private/ libsvn_subr/ svn/ svnbench/ svnmucc/ svnrdump/ svnsync/ tests/cmdline/getopt_tests_data/

From: Philip Martin <philip.martin_at_wandisco.com>
Date: Mon, 11 May 2015 17:32:54 +0100

rhuijben_at_apache.org writes:

> Author: rhuijben
> Date: Mon May 11 11:56:46 2015
> New Revision: 1678734

> +svn_error_t *
> +svn_cmdline__parse_trust_options(
> + svn_boolean_t *trust_server_cert_unknown_ca,
> + svn_boolean_t *trust_server_cert_cn_mismatch,
> + svn_boolean_t *trust_server_cert_expired,
> + svn_boolean_t *trust_server_cert_not_yet_valid,
> + svn_boolean_t *trust_server_cert_other_failure,
> + const char *opt_arg,
> + const char *error_prefix,
> + apr_pool_t *scratch_pool)

> + return svn_error_createf(SVN_ERR_CL_ARG_PARSING_ERROR, NULL,
> + _("%sUnknown value '%s' for %s.\n"
> + "Supported values: %s"),
> + error_prefix ? error_prefix : "",
> + value,
> + "--trust-server-cert-failures",
> + "unknown-ca, cn-mismatch, expired, "
> + "not-yet-valid, other");

Why are you using error_prefix here? We don't usually do that. It
leads to output like "svn: E205000: svn:" with duplicate "svn:"

$ svn ls --trust-server-cert-failures foo --non-interactive
svn: E205000: svn: Unknown value 'foo' for --trust-server-cert-failures.
Supported values: unknown-ca, cn-mismatch, expired, not-yet-valid, other

-- 
Philip Martin | Subversion Committer
WANdisco // *Non-Stop Data*
Received on 2015-05-11 18:33:11 CEST

This is an archived mail posted to the Subversion Dev mailing list.