# # # patch "ChangeLog" # from [46a87b1400a1b8af5e049b0eb7cbf4a2423ea85a] # to [f06db592fc2a60e52ee75a5b75dd3fa7a8a4df4b] # # patch "commands.cc" # from [44ef6fcd7921bd4be0ee3ea14a043d9727fcc77a] # to [edad81ce79f71e29ceb864e18b6ec6f63b4b8736] # ============================================================ --- ChangeLog 46a87b1400a1b8af5e049b0eb7cbf4a2423ea85a +++ ChangeLog f06db592fc2a60e52ee75a5b75dd3fa7a8a4df4b @@ -1,5 +1,10 @@ 2006-03-12 Benoît Dejean + * commands.cc: log: retrieve changes summary and ancestors only when + needed. + +2006-03-12 Benoît Dejean + * po/fr.po: Small fixes. 2006-03-12 Matthew Gregan ============================================================ --- commands.cc 44ef6fcd7921bd4be0ee3ea14a043d9727fcc77a +++ commands.cc edad81ce79f71e29ceb864e18b6ec6f63b4b8736 @@ -51,6 +51,8 @@ #include "roster_merge.hh" #include "roster.hh" +#include + // // this file defines the task-oriented "top level" commands which can be // issued as part of a monotone command line. the command line can only @@ -3703,17 +3705,6 @@ print_this = true; } - changes_summary csum; - - set ancestors; - - for (edge_map::const_iterator e = rev.edges.begin(); - e != rev.edges.end(); ++e) - { - ancestors.insert(edge_old_revision(e)); - csum.add_change_set(edge_changes(e)); - } - if (next > 0) { set children; @@ -3748,6 +3739,17 @@ << endl; cout << "Revision: " << rid << endl; + changes_summary csum; + + set ancestors; + + for (edge_map::const_iterator e = rev.edges.begin(); + e != rev.edges.end(); ++e) + { + ancestors.insert(edge_old_revision(e)); + csum.add_change_set(edge_changes(e)); + } + for (set::const_iterator anc = ancestors.begin(); anc != ancestors.end(); ++anc) cout << "Ancestor: " << *anc << endl;