~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/repository.py

  • Committer: Andrew Bennetts
  • Date: 2009-06-15 08:01:21 UTC
  • mto: This revision was merged to the branch mainline in revision 4446.
  • Revision ID: andrew.bennetts@canonical.com-20090615080121-ef0m1mj83qjv6gc6
Fix bug when partial_history == [stop_revision]

Show diffs side-by-side

added added

removed removed

Lines of Context:
4471
4471
    iterator = repo.iter_reverse_revision_history(start_revision)
4472
4472
    try:
4473
4473
        #skip the last revision in the list
4474
 
        next_revision = iterator.next()
 
4474
        iterator.next()
4475
4475
        while True:
4476
4476
            if (stop_index is not None and
4477
4477
                len(partial_history_cache) > stop_index):
4478
4478
                break
 
4479
            if partial_history_cache[-1] == stop_revision:
 
4480
                break
4479
4481
            revision_id = iterator.next()
4480
4482
            partial_history_cache.append(revision_id)
4481
 
            if revision_id == stop_revision:
4482
 
                break
4483
4483
    except StopIteration:
4484
4484
        # No more history
4485
4485
        return