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

problem interrupting 'svn log' (may be a Neon issue)

From: Karl Fogel <kfogel_at_newton.ch.collab.net>
Date: 2003-03-17 23:34:35 CET

kfogel@tigris.org writes:
> Log:
> Now that we handle sigint, 'svn log' needs to explicitly pay attention
> to cancellation. This is an addendum to issue #1004.

There's still a problem here, though, a rather mysterious one.

If you type ^C while running 'svn log' on the whole Subversion
repository, the output will now stop immediately. But your prompt
won't come back immediately -- instead, svn will wait until all the
network data has been received, and *then* give you your prompt back.
(At least, that's what my network activity light seems to be
indicating. :-) )

At first, I thought I knew how to solve this:

   "Aha, I just have to go into the RA layers and make sure that when
    the `log_receiver' func returns SVN_ERR_CANCELLED, the receiver's
    caller stops parsing incoming data and returns the same error
    immediately."

But ra_dav should *already* be doing that. Specifically, in
libsvn_ra_dav/log.c:log_end_element(), we store the receiver's error
in a baton and then return NE_XML_INVALID. Since neon/src/ne_xml.h
says this

     NE_XML_INVALID ->
        No, this is NOT valid XML, and parsing should stop.

...I expect libsvn_ra_dav/util.c:svn_ra_dav__parsed_request() to
return immediately.

Admittedly, the full context of that comment is:

   /* Function to check element context...
      This callback must return:
        NE_XML_VALID ->
           Yes, this is valid XML, and I want to handle this element.
        NE_XML_INVALID ->
           No, this is NOT valid XML, and parsing should stop.
        NE_XML_DECLINE ->
           I don't know anything about this element, someone else
           can handle it.
   */

... and it's not quite clear what function is being referred to. But
anyway, my understanding of NE_XML_INVALID has always been that it
stops the parsing right away.

However, since ra_dav appears to be eating all the rest of the data
from the server before returning to the client library, I guess
parsing isn't stopping?

I can debug this further, but I'm posting early to see if it rings
bells for anyone...

-Karl

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Tue Mar 18 00:12:59 2003

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.