Commit 237b0053 authored by Sebastian Kummer's avatar Sebastian Kummer

ZP-865 Abort conflict detection if there are more 100 changes to be

exported.

Released under the Affero GNU General Public License (AGPL) version 3.
parent 179d735c
...@@ -309,6 +309,11 @@ class ImportChangesICS implements IImportChanges { ...@@ -309,6 +309,11 @@ class ImportChangesICS implements IImportChanges {
// monitor how long it takes to export potential conflicts // monitor how long it takes to export potential conflicts
// if this takes "too long" we cancel this operation! // if this takes "too long" we cancel this operation!
$potConflicts = $exporter->GetChangeCount(); $potConflicts = $exporter->GetChangeCount();
if ($potConflicts > 100) {
ZLog::Write(LOGLEVEL_WARN, sprintf("ImportChangesICS->lazyLoadConflicts(): conflict detection abandoned as there are too many (%d) changes to be exported.", $potConflicts));
$this->conflictsLoaded = true;
return;
}
$started = time(); $started = time();
$exported = 0; $exported = 0;
try { try {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment