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

Re: [PATCH] Augment the awful "200 OK" error message when can't connect to repository

From: Ivan Zhakov <ivan_at_visualsvn.com>
Date: Mon, 11 Jan 2010 19:44:08 +0300

On Mon, Jan 11, 2010 at 1:29 PM, Philip Martin
<philip.martin_at_wandisco.com> wrote:
> Ivan Zhakov <ivan_at_visualsvn.com> writes:
>
>> -  return ne_xml_parse(pwb->parser, data, len);
>> +  parser_status = ne_xml_parse(pwb->parser, data, len);
>> +  if (parser_status)
>> +  {
>> +      /* Pass XML parser error. */
>> +      ne_set_error(pwb->req->ne_sess, "%s", ne_xml_get_error(pwb->parser));
>> +  }
>> +
>> +  return parser_status;
>
> There's another call to ne_xml_parse in that file, in
> parse_spool_file. Should we make the same change there?
>
Good point, but XML parser neon is wrapped in parsed_request()
function after calling parse_spool_file(). I updated my patch to
return the same error message as parsed_request():
[[[
svn: The OPTIONS request returned invalid XML in the response: XML parse error a
t line 1: no element found (https://svn.apache.org/repos/)
]]]

I like my original error message, but consistency is more important IMHO.

-- 
Ivan Zhakov
VisualSVN Team

Received on 2010-01-11 17:44:41 CET

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.