Hi Andy,

On 9/6/2016 3:26 PM, Andy Goth wrote:
That seems to fix it. Thank you very much for the astonishingly fast turnaround. There may be unintended consequences since we haven't done much analysis yet, so I checked your change in on the merge-rename-lockup branch pending further testing.

On Tue, Sep 6, 2016 at 2:20 PM, Richard Hipp <d...@sqlite.org <mailto:d...@sqlite.org>> wrote:

    On 9/6/16, Andy Goth <andrew.m.g...@gmail.com
    <mailto:andrew.m.g...@gmail.com>> wrote:
    >
    > The repository is private, sorry, but I should be able to help with
    > debugging.
    >

    Just a guess:

    Index: src/merge.c
    ==================================================================
    --- src/merge.c
    +++ src/merge.c
    @@ -395,11 +395,11 @@
       }
       if( zPivot ){
         vAncestor = db_exists(
           "WITH RECURSIVE ancestor(id) AS ("
           "  VALUES(%d)"
    -      "  UNION ALL"
    +      "  UNION"
           "  SELECT pid FROM plink, ancestor"
           "   WHERE cid=ancestor.id <http://ancestor.id> AND pid!=%d
    AND cid!=%d)"
           "SELECT 1 FROM ancestor WHERE id=%d LIMIT 1",
           vid, nid, pid, pid
         ) ? 'p' : 'n';


This is the right fix. It ensures that each commit is only added to the queue by the recursive SELECT once instead of an exponential number of times based on how many merge commits it finds along the way, which is what caused your problem. I don't know why I used UNION ALL there, but it's definitely wrong.
_______________________________________________
fossil-users mailing list
fossil-users@lists.fossil-scm.org
http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users

Reply via email to