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

Re: permissions (and other) problems

From: Philip Martin <philip_at_codematters.co.uk>
Date: 2002-09-14 21:39:11 CEST

Garrett Rooney <rooneg@electricjellyfish.net> writes:

> i thought of that, but it raises an interesting question. is it more
> important to get the line number of where you were canceled, or to
> have the user defined cancelation function be able to annotate the
> error with some indication of why you were canceled? something worth
> thinking about.

Well, the client can record and report the reason independently of the
svn_error_t. The line number information, on the other hand, once
lost has gone for ever.

> > Note that as far as asynchronous signals go, it doesn't really matter
> > whether SVN_ERR calls the cancel function before or after expr, so it
> > can be written
>
> i thought of that, but i figured since we've already been told to stop
> doing work, we might as well make that check happen before we go off
> and do any other work.

You have missed that the cancel state will (usually) get set
asynchronously. So it may not be set before calling expr, it may get
set *during* expr, and then be set after expr. In general, it makes
no difference whether you check before or after expr, neither one is
more immediate, or "faster", than the other. So just pick which ever
produces the cleanest code.

-- 
Philip Martin
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Sat Sep 14 21:40:05 2002

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.