Ticket Change Details
Not logged in
Overview

Artifact ID: f3c0c5e2dddf63fa52deef0a22ec0da0adcba059
Ticket: 2a1e8e3c4b0b39e08fdde0d24d9fb35fbc66d39a
content_get can recursive too deep
User & Date: anonymous 2010-10-04 10:00:21
Changes

  1. Appended to comment:
    
    
    <hr /><i>anonymous added on 2010-10-04 10:00:21:</i><br />
    I'm seeing this as part of the rebuild step of reconstruct and clone. I haven't tried "fossil rebuild". With "fossil clone", the stack nesting is deep enough to hit the stack limit. Backtrace starts with a few thousand content_get and ends with a few thousand of:
    
    #14478 0x000000000040d6a0 in after_dephantomize (rid=25789, linkFlag=1) at content_.c:361
    
    I can't share this repository, but the problematic part is a single file that has ~3000 commits, incrementally extending it. Think of a ChangeLog if you want.
    
    I think the best approach here is to avoid deep recursions by limiting the length of a delta chain. What do you think about storing the start and depth of the delta chain with each delta and introducing an on-disk content cache to cut it when it reaches a specific limit. Phantoms could be processed as forward process without recursion by using a small todo bag.