diff --git a/thorlcr/activities/join/thjoinslave.cpp b/thorlcr/activities/join/thjoinslave.cpp index f2262256ab7..f6e11533003 100644 --- a/thorlcr/activities/join/thjoinslave.cpp +++ b/thorlcr/activities/join/thjoinslave.cpp @@ -265,8 +265,8 @@ class JoinSlaveActivity : public CSlaveActivity, implements ILookAheadStopNotify { try { + LookAheadTimer t(slaveTimerStats, timeActivities); startInput(secondaryInputIndex); - if (ensureStartFTLookAhead(secondaryInputIndex)) { IThorDataLink *secondaryInput = queryInput(secondaryInputIndex); diff --git a/thorlcr/activities/keyedjoin/thkeyedjoinslave.cpp b/thorlcr/activities/keyedjoin/thkeyedjoinslave.cpp index 46e7a05302c..b27bf59be4b 100644 --- a/thorlcr/activities/keyedjoin/thkeyedjoinslave.cpp +++ b/thorlcr/activities/keyedjoin/thkeyedjoinslave.cpp @@ -2675,13 +2675,18 @@ class CKeyedJoinSlave : public CSlaveActivity, implements IJoinProcessor, implem { if (queryAbortSoon()) break; - OwnedConstThorRow lhsRow = inputStream->nextRow(); - if (!lhsRow) + OwnedConstThorRow lhsRow; { - groupStart = nullptr; // NB: only ever set if preserveGroups on + LookAheadTimer t(slaveTimerStats, timeActivities); + lhsRow.setown(inputStream->nextRow()); if (!lhsRow) - break; + { + groupStart = nullptr; // NB: only ever set if preserveGroups on + lhsRow.setown(inputStream->nextRow()); + if (!lhsRow) + break; + } } Linked jg; if (helper->leftCanMatch(lhsRow))