Show More
@@ -462,6 +462,16 b' class marker(object):' | |||||
462 | """The flags field of the marker""" |
|
462 | """The flags field of the marker""" | |
463 | return self._data[2] |
|
463 | return self._data[2] | |
464 |
|
464 | |||
|
465 | def _checkinvalidmarkers(obsstore): | |||
|
466 | """search for marker with invalid data and raise error if needed | |||
|
467 | ||||
|
468 | Exist as a separated function to allow the evolve extension for a more | |||
|
469 | subtle handling. | |||
|
470 | """ | |||
|
471 | if node.nullid in obsstore.precursors: | |||
|
472 | raise util.Abort(_('bad obsolescence marker detected: ' | |||
|
473 | 'invalid successors nullid')) | |||
|
474 | ||||
465 | class obsstore(object): |
|
475 | class obsstore(object): | |
466 | """Store obsolete markers |
|
476 | """Store obsolete markers | |
467 |
|
477 | |||
@@ -598,9 +608,8 b' class obsstore(object):' | |||||
598 | if parents is not None: |
|
608 | if parents is not None: | |
599 | for p in parents: |
|
609 | for p in parents: | |
600 | self.children.setdefault(p, set()).add(mark) |
|
610 | self.children.setdefault(p, set()).add(mark) | |
601 | if node.nullid in self.precursors: |
|
611 | _checkinvalidmarkers(self) | |
602 | raise util.Abort(_('bad obsolescence marker detected: ' |
|
612 | ||
603 | 'invalid successors nullid')) |
|
|||
604 | def relevantmarkers(self, nodes): |
|
613 | def relevantmarkers(self, nodes): | |
605 | """return a set of all obsolescence markers relevant to a set of nodes. |
|
614 | """return a set of all obsolescence markers relevant to a set of nodes. | |
606 |
|
615 |
General Comments 0
You need to be logged in to leave comments.
Login now