[MERGE] Make cmd_branch check the destination before doing any I/O on the source.

John Arbash Meinel john at arbash-meinel.com
Fri Jul 7 05:24:56 BST 2006


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

IMichael Ellerman wrote:
> On Thu, 2006-07-06 at 09:06 -0500, John Arbash Meinel wrote:
>> Michael Ellerman wrote:
>>> Hi list,
>>>
>>> This rearranges some logic in cmd_branch so that we check the destination
>>> before doing any I/O on the source branch. This is nice for branching
>>> from a remote to a local branch on slow links, if there's something wrong
>>> with the destination you find out quickly. A test is included.
>>  
>> Good but not great. The reason we connect to the remote branch first is
>> that we don't want to create the local directory if the user types the
>> wrong remote path. Which is probably more common than a user running
>> into a local error.
>>

...

> 
> Yeah, fair enough, that would be annoying. Scrap it.
> 
> cheers
> 

I wasn't thinking to completely scrap it, just cleanup the mkdir if you
fail the rest.
(Just like our locking lock A, then B, but if B fails, unlock A)

John
=:->

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (Darwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFEreIYJdeBCYSNAAMRAhZbAKCX6CN9AjSS+ZY2hY/HCUETETTpMQCfedtT
9IhVkc3ONlUTX/YbU114VEY=
=fQdZ
-----END PGP SIGNATURE-----




More information about the bazaar mailing list