Skip to content

Commit b36b8b6

Browse files
Merge pull request #87 from salesforce/build-fix-stream-mode
Add default ctor in ChangeList class
2 parents e21ee28 + d82d114 commit b36b8b6

File tree

2 files changed

+2
-0
lines changed

2 files changed

+2
-0
lines changed

p4-fusion/commands/change_list.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ struct ChangeList
3535
int filesDownloaded;
3636
State state;
3737

38+
ChangeList() = default; // Defaulted so that vector<ChangeList>::resize() can be used.
3839
ChangeList(const std::string& number, const std::string& description, const std::string& user, const int64_t& timestamp);
3940

4041
ChangeList(const ChangeList& other) = delete;

p4-fusion/main.cc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -294,6 +294,7 @@ int Main(int argc, char** argv)
294294
// Truncate excess changes
295295
if ((maxChanges > -1) && (changes.size() > maxChanges))
296296
{
297+
// We don't need to consider the case if this ever expands the vector.
297298
changes.resize(maxChanges);
298299
}
299300
}

0 commit comments

Comments
 (0)