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

Re: svn commit: r1499386 - in /subversion/trunk/subversion/libsvn_ra_serf: ra_serf.h util.c xml.c

From: Greg Stein <gstein_at_gmail.com>
Date: Thu, 4 Jul 2013 13:59:27 -0400

On Wed, Jul 3, 2013 at 9:13 AM, <rhuijben_at_apache.org> wrote:
>...
> +++ subversion/trunk/subversion/libsvn_ra_serf/util.c Wed Jul 3 13:13:49 2013
>...
> @@ -2564,12 +2575,7 @@ expat_response_handler(serf_request_t *r
>
> If an error is not present, THEN we go ahead and look for parsing
> errors. */
> - if (ectx->inner_error)
> - {
> - apr_pool_cleanup_run(ectx->cleanup_pool, &ectx->parser,
> - xml_parser_cleanup);
> - return svn_error_trace(ectx->inner_error);
> - }
> + SVN_ERR(ectx->inner_error);

Why the removal of the cleanup?

>...
> +++ subversion/trunk/subversion/libsvn_ra_serf/xml.c Wed Jul 3 13:13:49 2013
>...
> + if (document)
> + msg = apr_psprintf(xmlctx->scratch_pool, "'%s' element not found",
> + document->name);
> + else
> + msg = _("document element not found");
> +
> + return svn_error_createf(SVN_ERR_XML_MALFORMED, NULL,
> + _("XML stream truncated: %s"),
> + msg);

You could end up with mixed language here. "$TRANS(XML stream
truncated: )$ENGLISH('FOO' element not found)"

It seems that you'd want to have two separate svn_error_createf()
calls, with different args. That'll get the translation stuff right.

>...

Cheers,
-g
Received on 2013-07-04 20:00:03 CEST

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

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.