On Wed, Jul 3, 2013 at 11:53 PM, Stephan Beal <sgb...@googlemail.com> wrote:
> On Wed, Jul 3, 2013 at 11:50 PM, Richard Hipp <d...@sqlite.org> wrote: > >> I agree, "fossil gdiff" should not keep the database locked. FWIW, the >> "fossil diff --tk" command does not keep the database locked, at least not >> that I have noticed. If "fossil gdiff" is locking the database, probably >> the reason it has not been fixed is that I never used "gdiff" myself and so >> have not noticed the problem. >> > > Please let us know if you fix this, otherwise i'll take a look at it in > the next 20 hours or so. > Here's my proposed patch, but i'm not at all sure if this is the proper fix: [stephan@host:~/cvs/fossil/fossil/src]$ f diff diffcmd.c --- diffcmd.c +++ diffcmd.c @@ -171,10 +171,11 @@ blob_appendf(&cmd, "%s ", zDiffCmd); shell_escape(&cmd, blob_str(&nameFile1)); blob_append(&cmd, " ", 1); shell_escape(&cmd, zFile2); + db_close(0); /* Run the external diff command */ fossil_system(blob_str(&cmd)); /* Delete the temporary file and clean up memory used */ file_delete(blob_str(&nameFile1)); with that i am able to do things on the db while a gdiff is running w/o getting a locking error, but this certainly should be tested under the OP's conditions before i'm comfortable committing this. @Matt: please try adding the above line to your copy. The change is in diffcmd.c:diff_file(), line 176 (vs. the current trunk). -- ----- stephan beal http://wanderinghorse.net/home/stephan/ http://gplus.to/sgbeal
_______________________________________________ fossil-users mailing list fossil-users@lists.fossil-scm.org http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users