Fixing a confusion on filename conflicts, where some names could be mistakenly treated as zombies

pmeunier
Jan 4, 2022, 10:55 AM
422NG2MT6M7YQDX2LFZSSHGP73BX76AXUWK64VID7TO5Y4JBWJCQC

Dependencies

Change contents

  • replacement in libpijul/src/apply/edge.rs at line 39
    [3.97339][3.97339:97389]()
    if !n.flag.contains(EdgeFlags::DELETED) {
    [3.97339]
    [2.1461]
    if (n.flag & EdgeFlags::df()).is_empty() {
    // Inside a file, nondeleted zombies occur when we are
    // re-introducing an alive edge (for example to solve a
    // zombie conflict), and another, unknown patch deleted
    // the context in parallel.
    //
    // For folder edges, children or parents are either on the
    // same level as this edge (i.e. to/from a basename
    // vertex), in which case the zombie nature of the file
    // will be detected at output and record time.
    //
    // Or the children or parents are at different levels,
    // which isn't a zombie conflict, since it is normal
    // commutation between folder operations.
    //
    // This justifies the EdgeFlags::df() exclusion above.
  • edit in libpijul/src/apply/edge.rs at line 88
    [3.98589]
    [3.98589]
    assert!(!n.flag.contains(EdgeFlags::FOLDER));
  • edit in libpijul/src/apply/edge.rs at line 128
    [3.99613]
    [3.99613]
    // Iter through deleted parents of the edge's source. Any unknown
    // edge points towards a zombie.
  • edit in libpijul/src/apply/edge.rs at line 138
    [3.99841]
    [3.99841]
    // Iter through the children of the non-deleted target. Any deleted
    // parent of a child makes the child a zombie.